Is there a way to prevent a bad actor from using your AirTag to track you?

Airtag's don't work that way: Others are not alerted to your Airtag immediately or likely at all, since it is with you. And no one can register your Airtag until you de-register it.

Airtag's are registered to an AppleID, not an item. Once registered, they can't be registered to another AppleID, unless the previous registration is removed by that owner. If by 'devices' you mean info on what iPhone has registered the Airtag, this information is private and not revealed. So you will see no information in 'Find My' about the iPhone or owner of the iPhone, only whatever name was given to the Airtag. (You will see location of course).

When an Airtag is found, the finder can not 'register' that Airtag. They can touch the Airtag with their iPhone and a webpage will provide them with the ability to send a message to the Airtag owner if it has been lost.

Airtags do not alert others of their presence immediately. They must be away from the owner and moving with the non-owner for a 'period of time". Apple's support page tells us that:

To discourage tracking without your knowledge, Find My will notify you if an unknown AirTag or other Find My network accessory is seen moving with you over time. An AirTag that isn't with the person who registered it for an extended period of time will also play a sound when moved so you can find it, even if you don’t use an iOS device.

Finally, since you register an Airtag with your AppleID, any 'devices' that are also signed into your AppleID will be able to see and control that Airtag. For example, our Mac, or iPad. You don't get an alert because those devices share your AppleID, so it knows its 'you'.