This'll be crazy but fun....
While I am a professed Catholic, and raised christian; my mind is also quite attracted to the Hindu perception of mind, self and spirit as well as its eclectic collection in its concept of the divine bound within the unity Brahma.
So... From a Christian perspective, its a no-but, in that we're made with physical and mental gender, and there's no basis to believe the resurrected/glorified body would be different in that regard; so as embodiment is always in play, thus, so is gender and physical sex.
otoh, my admittedly weaker understanding of the Hindu side leads me on a different path; in that bodies are taken, lived, discarded at death, Karma is balanced in the spiritual realm, and then a new body taken up; but there is *choice* involved. A spirit/self has some agency here, so a spirit that has been comfortably male before, may choose to continue that pattern. In this context, I have a completely parallel understanding of how I came to be as I am (gender and otherwise), which is not particularly scientific, shall we say... So the spirit here does not have gender, but may have a preference for one or the other, which leads to actual consequence.
nb.. for entertainment purposes only: my perception acquired through meditation in Hindu context is that my spirit has been female for some number of cycles, but quite violent with ample opportunity to carry out that violence, but this time around went with a male body; but then got doubly jipped by this brain being coded feminine during development, followed by an upbringing that successfully taught me a fairly strict pacifism, which I strive to perfect to this day.. I think the spirit is resentful for this turn of events, but is learning to accept a new, peaceful way of life. :-D