The standard teaching in churches it that Ruth was a physical descendant of Moab. Here is why that is not true.
The land of Moab was taken away from Moab by two kings of the Ammorites. Sihon king of Heshbon and by Og king of Bashan. Yahweh God gave the land they possessed to Israel. This land then became the home to the two and a half tribes of Israel. That is Gad, Reuben and the half tribe of Manasseh. The land retained its name, the Land of Moab, just like the land of Canaan.
You will find the explanation for this in Deuteronomy 2:24 through 3:22.
Here is a summary about how Israel took the land that had been the Land of Moab.
Numbers 21:26 “For Heshbon was the city of Sihon the king of the Amorites, who had fought against the former king of Moab, and taken all his land out of his hand, even unto Arnon.”
Remember that by the time of Deuteronomy 2:24 through 3:22, Israel had already passed by where Moab was currently living and they had gone around Edom before all this happened.
It was about 250 years later that Ruth was born. She was born to parents who were of one of the three tribes of Israel who had opted for an inheritance on the East side of Jordan. She grew up knowing that she was from the land called the Land of Moab. Being separated from the rest of Israel she did not know she was an Israelite. The book of Jasher shows that the tribes East of Jordan had made a commitment to not forget their God or His Law. Through the times of the judges it is not really a surprise to find they did.
When Naomi went home to the land of Judah, Ruth went with her. There Boaz and the rest of the town recognized that Ruth was an Israelite as they treated her as one. If she had been a true foreigner they would never have given her the position of a daughter.