When did the Old and New Testament distinction originate?
The distinction was necessitated by the Jew's rejection of the books included in the New Testament.
The new covenant is new because it is different from the old, the covenant God made with the nation of Israel through the prophet Moses.
The prophet Jeremiah spoke of the covenant that was to come.
Jeremiah 31:31 "Behold, days are coming," declares the LORD, "when I will make a new covenant with the house of Israel and with the house of Judah,
Jeremiah 31:32 not like the covenant which I made with their fathers in the day I took them by the hand to bring them out of the land of Egypt, My covenant which they broke, although I was a husband to them," declares the LORD.
Jeremiah 31:33 "But this is the covenant which I will make with the house of Israel after those days," declares the LORD, "I will put My law within them and on their heart I will write it; and I will be their God, and they shall be My people.
Jeremiah 31:34 "They will not teach again, each man his neighbor and each man his brother, saying, 'Know the LORD,' for they will all know Me, from the least of them to the greatest of them," declares the LORD, "for I will forgive their iniquity, and their sin I will remember no more."
Note that the covenant that is "old" is the one God made through the prophet Moses. That means that even though Christians sometimes divide the Bible into the Old and New Covenants, there is much even in the Torah that came before the old covenant came to be.
The writter of the book of Hebrews, in the Christian "NT", speaks of Jeremiah's words thus:
Hebrews 8:13 When He said, "A new
covenant," He has made the first obsolete. But whatever is becoming obsolete and growing old is ready to disappear.