Internal identity does not match biological external identity

How could gender role socialization impact a person negatively when their internal identity does not match their biological external identity?