Ref. No. 41/1014
In the name of Allah the most gracious the most merciful
The answer to your question is as follows:
If a woman performs namaz in masjid, her namaz is valid. However, the best namaaz of women is inside the deepest corner of her house as it is mentioned in hadith. If a woman is ourdoor at the time of namaz, she can go to a nearby mosque where there is a special arrangement for the ladies and offer individually at a separate section in the masjid, so that a woman does not miss out on obligatory prayers.
And Allah knows best
Darul Ifta
Darul Uloom Waqf Deoband