It was/is a very common part of tribal warfare. Even the Russians are accused of it in Ukraine.
It has been a part of warfare for a very long time, longer than recorded history, for certain.
A different form was done by the Russians in Germany in 1945. ape of German women was a matter of policy in order to leave a lot of Russian genes in Germany. Plus, of course, the women were regarded as “spoils of war.”
Numbers 31:17-18
"Now therefore kill every male among the little ones, and kill every woman that hath known man by lying with him. But all the women children, that have not known a man by lying with him, keep alive for yourselves."