Of course they can control their behavior; what they cannot change is their preference and the desire it creates. Whether hard-wired or developmental, it is involuntary. For that very reason, having them in the military carries significant risks, which our political culture now chooses to ignore in favor of either self-delusion or radical purpose.
I’m not convinced that they cannot change their preference, but I do believe that it is a disorder, a form of mental illness. The military should not have to accept the mentally ill. That’s not their job.