Mt. 1:22 - 23
Matthew
22: All this took place to fulfill what the Lord had said through the prophet:
23: Behold, the virgin will be with child and will give birth to a son, and they will call Him Immanuel (which means, “God with us”).
Matthew is quoting Isaiah 7:14 here, which reads as follows:
הִנֵּה הָעַלְמָה, הָרָה וְיֹלֶדֶת בֵּן,
a son and bear she will concieve the young woman Look!
וְקָרָאת שְׁמוֹ, עִמָּ֥נוּ אֵל
God with us his name and she will call
The Hebrew word הָעַלְמָה literally means, "the young woman of marriageable age" In this case the woman could have been a virgin at the time of Isaiah's prophesy to king Ahaz. (Premarital sex was unknown in Israel at the time.)
But the word also means, "the newlywed young woman."
As Isaiah does not explicitly say that she gave birth while still a virgin, we can safely assume that the virgin married a man, and the couple then conceived a child.
The idea of predicting the miraculous birth of a boy by a virgin, was not present in the mind of the Isaiah author at that time.
If the author wanted this to clearly be a virgin birth, he could have used the Hebrew word בְּתוּלָה which unambiguously means, "virgin" as in Gen 24:16.
There is no doubt that Mary was a virgin. Mt. 1:18, 1:25 and Lk. 1:26, 1:34.
However, we should keep in mind that the text that Matthew is quoting was written
a) in a specific set of circumstances: two kings "marched up to wage war against Jerusalem" (Is 7:1),
b) to specific audience: "the hearts of Ahaz and his people trembled" (Is 7:2),
c) for a specific reason:"Calm down and be quiet. Do not be afraid or disheartened" (Is 7:4).
My personal opinion
The boy in Isaiah had a human father and mother. The boy Jesus already had a Father, and needed a human mother in order to become a human being and then, by His life, work, suffering, death, and resurrection, be able to complete God's plan of Salvation.
Most importantly:
Both boys were called "Immanuel" "God with us"
In Isaiah,
king Ahaz and his people had to be assured that God was with them in that particular situation.
In Matthew,
a) the Apostle reminds us that centuries before Jesus, there was another boy called "Immanuel"
b) and he then proclaims that with the birth of Jesus, God is with us forever.