True. But eunuchs are still men. Just mutilated men. They still have Y chromosomes.
Sex is a phenotype, not a genotype.
Genes do not directly dictate sex.
If there are certain types of damage the brain and body will even develop as female (see complete androgen insensitivity syndrome) so God’s recognition of a difference between men, women, and the mutilated or malformed is not obsolete.
God places them in their own category. Commandments on sexual morality still apply, and most of them are still mired in sexual sins, but there are also a lot of them (obviously not the hookers) who become celibate.