All perfect praise be to Allah, the Lord of the worlds. I testify that none is worthy of worship except Allah and that Muhammad, sallallaahu ‘alayhi wa sallam, is His slave and messenger.
The scholars agreed that fasting is forbidden for a woman during her menses, and it is not accepted from her if she fasts, as the Prophet, sallallaahu ‘alayhi wa sallam, said, “Is it not true that when one of you menstruates, she neither prays nor fasts…” [Al-Bukhari and Muslim]
If her menses come while fasting, then the fast is invalidated. However, Allah Almighty never wastes the deeds of a worshiper. She is rewarded for her good intention. The Prophet, sallallaahu ‘alayhi wa sallam, said, “When a slave falls ill or travels, then he will get a reward similar to what he gets for the good deeds that he does when in good health and not traveling.” [Al-Bukhari narrated this Hadeeth on the authority of Abu Musa ]
Allah knows best.