Women are strongly recommended to take rest from practice during the first three heaviest days of their menstruation and then avoid inverted postures until the end of their cycle.
Ashtanga yoga is a very pranic practice, meaning energy is moving upwards. When we are menstruating this action is apanic meaning that the energy is going downwards. When we practice, particularly inversions (remembering that even downward dog is infact an inversion with the head lower than the pelvis), the apanic action can be counteracted by the pranic action. This can cause problems with the flow. it is not uncommon for women to suffer with losing their periods when they practice through their period and some ladies believe it can have an affect on trying to get pregnant later on.
It is best at these times to let our bodies rest and take advantage of this time to practice other aspects of yoga. Its also nice to be a bit lazy for a few days and have reason to eat cake!