All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger.
Both that man and that woman must repent to Allaah from committing Zina (fornication or adultery) and they should avoid having such a relationship again prior to marriage as it is a means of committing Zina. For more benefit, please refer to Fataawa 87903 and 81356.
That man and any other man should know that the only way in the Sharee’ah to enjoy a free woman is to marry her. Besides, the Islamic marriage has conditions without which it is void; the most important of which are the consent of the guardian and the presence of two witnesses. For more benefit in this regard, please refer to Fatwa 83629.
Hence, if that man had sexual intercourse with that woman as if she was his wife just based on his statement that he agrees to take her as his wife, then this does not render their relationship an Islamic marriage just because of what he did. Taking the Quran as a witness – as he says – is not sufficient.
However, if he believed that it was a correct marriage, then the child is traced back to him, because the jurists stated that every marriage in which the husband believed that it was a valid marriage, even if in itself it was void, then the children are traced back to him.
Allaah Knows best.