One person with the imam would constitute a congregation even if the other person is a child or a woman.
Ibn ‘Abbas says: “I stayed with my Aunt Maimunah and the Prophet sallallahu alehi wasallam got up to pray during the night. I got up to pray with him and stood on his left and the Prophet took me by my hand and put me on his right side.”
Sa’id and Abu Hurairah both report that the Prophet sallallahu alehi wasallam said: “Whoever gets up during the night and wakes up his spouse and they pray two rak’at together, they both will be recorded among those (men and women) who remember Allah much.” This is related by Abu Dawud. Abu Sa’ id narrates that a man entered the Mosque, and the Prophet and his companions had already prayed. The Prophet sallallahu alehi wasallam said: “Who will give charity to him by praying with him?” So, a man from the people stood and prayed with him. This is related by Ahmad, Abu Dawud, and at-Tirmizhi who calls it hasan. Ibn Abi Shaibah relates that it was Abu Bakr who stood and prayed with the man. At-Tirmizhi uses this hadith as proof that a group can pray in congregation in a mosque in which the congregational prayer had already been made. He says that this is the opinion of Ahmad and Ishaq. Other scholars say that they should each pray individually and this is the opinion of Sufyan, Malik, Ibn al-Mubarak and ash-Shaf’i.