James 4:1-10

Internal conflict. When desires are left unfulfilled it can lead to extreme frustration. You never know where pursuing a strong desire can lead you. If someone is quarreling it is because they aren't getting what they want.

Why don't we get what we want? If you ignore your relationship with God (prayerless: maybe don't believe God cares, maybe know that what they want is wrong). It may be ineffective prayer (treating God as a "genie" to grant our desires, or God sees an issue in what we're asking, or maybe the timing is not in line with his will.)
When we choose to turn to the world for satisfaction instead of God we commit spiritual adultery.
The world is offering the opposite of what God is; it is a false promise.
The "spirit" James refers to could be our soul, the Holy Spirit, or the nature we have that urges us to disobey God. We can either submit to our desires or turn to God for guidance. We must resist Satan by trusting God.
Repent and draw near to God first. Then work on yourself - pray for God to change your problem areas. Then you can work on other relationships.