Because they feel threatened
Jealousy in many cases happens when a person feels threatened by someone else. If, for example, a man got afraid that another man might steal his wife then this man will experience jealousy.
Jealousy usually happens when there is a perceived competition. If an employee saw another employee being praised by their manager then the first might feel jealous because of being afraid to lose the promotion they wanted to get.
Insecurity causes jealousy
The person who feels insecure is much more likely to get jealous. If a person was 100% sure they can win in spite of the competition then they might not feel jealous.
Jealousy and motivation
Jealousy can have the purpose of motivating a person to become better usually when combined with feelings of inferiority. When a person sees their friends or peers doing better than them, they might get motivated to improve themselves.
Inferiority causes jealousy
When a person feels inferior to someone they might feel jealous of that person. (See What Causes an Inferiority Complex?)
Self doubts cause jealousy
If a person has self doubts then they are more likely to feel jealous of their friends and peers. Because that person believes they can’t compete with their friends, they feel jealous towards them.
Comparisons cause jealousy
The comparisons a person makes between themselves and others or having parents that keep making comparisons between their children can lead to intense jealousy.
When a person gets the resources someone wanted
If a person got the resources another person wanted then the latter might feel jealous. A person who needs attention might feel jealous of the celebrities who appear on TV because they took people’s attention. (See Why are some people are attention seekers?)
Hatred can cause jealousy
If a person hates another person, they are much more likely to feel jealous of them.
Believing that a person doesn’t deserve what they got
If a person believes that someone didn’t deserve what they got then they might feel jealous of them.
Bad past experiences
A person can feel jealous if they’ve been through some kind of a bad past experience that they don’t want to repeat. If someone stole a woman’s husband then she is very likely to experience more jealousy in her future relationships.
A person who distrusts themselves might fail to trust others. If a person isn’t sure of their own faithfulness then they might project those fears on others by being jealous.
Why are some people afraid to celebrate their birthdays? Why do I hate my birthday?