Sayyidah Aishah (may Allah be pleased with her) narrates that the Messenger of Allah (peace and blessings be upon him) would put his head out of the mosque while he (peace and blessings be upon him) was in i'tikaf, and I would wash it while I was menstruating.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصيام / 8575