Normally a baby receives an X from the mother and either an X or a Y from the father. Mostly, it is clear at birth from an external view whether they have XX for a girl or XY for a boy, but sometimes the appearance is confusing and a wrong attribution is made, causing the child to be brought up as though it is the wrong sex, causing problems later.
Any combination of chromosomes other than XX or XY is due to an anomaly in the transmission of those chromosomes from the two parents - as much of a genetic mistake as when a different extra chromosome produces a Down's Syndrome child. These X/Y anomalies can produce variations in sexual preference, but not always. There are many other factors involved in sexual preference, and in what gender an individual perceives themselves as.
The majority of those wishing to transition from male to female, or vice versa, are not doing so because of their chromosomes, but because their image of themselves doesn't match their chromosomal makeup which cannot be changed as it is inherent in every cell of their bodies, not just the primary and secondary sexual organs This is the difference between sex and gender.