Ruth was a beautiful foreign woman in the land. That's the danger.
https://www.biblegateway.com/resources/all-women-bible/ruth
Her name is a contraction of reuth, which may either be the word for “the act of seeing,” “sight” and hence, as in English, objectively “a sight,” “something worth seeing”—or the word for “friendship” or “a female friend,” like reu in Reuel, “friend of God.” If the former etymology be adopted, we must ascribe the name to the early beauty of the child; if the latter, it may be due to the exhibition in infancy of that amiable and affectionate disposition which was so characteristic of the woman.
Both meanings of the name were true of Ruth, for as a beautiful girl from Moab she was certainly a sight worth seeing, and her character revealed her to be a woman capable of rare friendship.
What were some prospects of a beautiful foreign woman alone in a field?
John Gill's Exposition of the Whole Bible
meet her in another field alone, or rush upon her at once and unawares, and reproach her, or beat her, or indeed force her
Pulpit Commentary mentions the danger of meeting "some lewd and lustful men".
So Naomi gave her some good advice in
Ruth 2:22
Naomi said to Ruth her daughter-in-law, “It will be good for you, my daughter, to go with the women who work for him, because in someone else’s field you might be harmed.”
It was double protection. She would be protected by the top boss Boaz and his working women so she would not be alone in the field. It was the smart advice of a caring mother-in-law.