@Laura4864 easy, just write it in your house rules and ask for their IDs on arrival. I am doing it all the time, and all hosts in Croatia, Italia, Spain, Slovenia, and many other countries where the host has an obligation to register his guests
I mean, knowing who has a key to your property is just common sense, I don't understand hosts who give access to their homes to total strangers they know anything about. And when their house is trashed or robbed they can't tell the police who did it. Hosts think Airbnb will tell their guest's names in case of such a problem but they won't and can't.