This is how the birth of Jesus Christ took place. When Mary his mother was engaged to Joseph, before they were married, she became pregnant by the Holy Spirit.
References for Matthew 1:18
Joseph her husband was a righteous man. Because he didn't want to humiliate her, he decided to call off their engagement quietly.
As he was thinking about this, an angel from the Lord appeared to him in a dream and said, "Joseph son of David, don't be afraid to take Mary as your wife, because the child she carries was conceived by the Holy Spirit.
She will give birth to a son, and you will call him Jesus, because he will save his people from their sins."
Now all of this took place so that what the Lord had spoken through the prophet would be fulfilled:
Look! A virgin will become pregnant and give birth to a son, And they will call him, Emmanuel. (Emmanuel means "God with us.")
References for Matthew 1:23
When Joseph woke up, he did just as an angel from God commanded and took Mary as his wife.
But he didn't have sexual relations with her until she gave birth to a son. Joseph called him Jesus.