The user wants the system to respect their identity and not force them to conform to an identity that doesn't match their own simply to use the app.
If the system does ask the user to provide a binary choice around identity—e.g. if a health app asks a user to choose between male and female—then the system explains why it necessary to reduce the options to only these choices, and qualifies what the implication of each is.
While ideally any app allows for the user to choose any gender, medical diagnosis normally requires a choice between binary male or female. The UI is not really the best place to discuss issues around the relationship between gender and sex and the social construction of both. Explaining the necessity of asking a reductive question in such a way as to make it clear that the system empathizes with the users concerns is tricky, yet it must try to do its best.