When I started looking feminine, I got hit on a lot- both by randoms and even within my group of friends. That continued to the point where I got used to it, and then I think I started putting off a different energy... One that kind of said "no" in a polite way where they don't even try. I think it's an eye contact or expression sort of thing. It's definitely something that cannot be taught, you just have to figure out yourself how to fend them off when you don't want it.
There will always be the pressing jerks that hit you up no matter what. You'll get better at dealing with those, too, as time goes on π