The idea that people have free will is a basic axiom of Torah. And we know the Torah forbids lots of stuff that people desire intensely. For example, "Thou shalt not murder." "Thou shalt not steal." Etc. "Thou shalt not bear false witness against thy neighbor." Lot of people lie. All Democrats use their power to steal (to vote for themselves other people's money). The fact that they can steal does not give them the right to. So we see people desire things the Torah tells them not to do.
So what to do if you desire things the Torah says not to do? My main idea is to learn Torah. That is especially Musar and the laws about the area you think you might be acting wrong.
[Musar here means books on Fear of God and ethics written during the Middle Ages or early Renaissance. ]
And I realize that not everyone can do what is right. But one thing you can do--you can refrain from recommending evil. Even if you can't refrain from sin, you can at least hold yourself back from trying to convince others to sin.
This is relevant to lots of issues. For example homosexuals desire something the Torah forbids. That does not give them the right to act on their desires. But even if they can't help themselves they should at lets refrain from trying to convince everyone else to be homosexuals. Even if they can't be decent people, they can at least want that others should be.
Now the actual law of homosexuality is this Females are allowed to play with each other. Males get the death penalty if there is penetration into the anus. If the males think the act is permitted then they bring a sin offering to the Temple in Jerusalem, [a goat or sheep]. If there are no witnesses they don't get the death penalty but they also can't bring a sin offering for an act done on purpose.