Demoting a Windows Domain Controller with Plex Installed

Plex settings are stored in the Windows user account.
The best strategy would be to move these settings and metadata to a dedicated partition or drive (an SSD preferably) in advance, so they are not affected by whatever operation you have to do with user accounts.

Make sure to save the contents of the Registry as well.
https://support.plex.tv/articles/201539237-backing-up-plex-media-server-data/