After purchasing your ticket for only 5 Mexican pesos ( 25 cents) proceed to the cars at the end of the metro, every metro usually leaves a car or two at the end for women and children under 12 years. You'll see this sign at the entrance of the women and children under 12 years' car.
However, the women's only subway policy only works mostly during peak hours, during off-peak hours you're most likely going to find men in the women's only car
Advice: Mexico city's subway was ranked the most dangerous subway last year. If you can help it avoid the subway during off-peak hours and only go for it during peak hours when the women-only subway policy is being enforced.