When the first human relationship is consummated in Genesis 2 the proper order for sexual relations is established. That is why a man leaves his father and mother and is united to his wife, and they become one flesh is what the Word of the Lord says in Genesis 2:24.
There is the leaving of the father and mother to be united with his wife and then there is the creating of the one flesh union. First, there is there is the event which leads to the marriage being established. Then there is the coming together of their bodies to cement the one flesh union. To have sex without the forming of the marriage is against this order.
Does it matter? Yes it most certainly does. Entering into the one flesh union without the marriage destroys the order. It is God’s design that a man and a woman first give themselves to each other, then they give their bodies to each other. Disturbing this order is always detrimental to the welfare of the couple.