The Messenger of Allah ﷺ would be in spiritual retreat in the mosque, and he would extend his head to me through the opening of my chamber so I could wash it. Musaddad's version says, "and I would comb it while I was menstruating."
حدثنا سليمان بن حرب ومسدد قالا حدثنا حماد بن زيد عن هشام بن عروة عن أبيه
كان رسول الله ﷺ يكون معتكفا في المسجد فيناولني رأسه من خلل الحجرة فأغسل رأسه وقال مسدد فأرجله وأنا حائض
Reference. Bukhari narrated it in the book of menstruation, chapter on a menstruating woman washing her husband's head and combing his hair, hadith no. 295, 2030, 5925, and Muslim, hadith no. 297, from the hadith of Hisham bin Urwa, with this wording.