Hard to say. If there are problems I'd check the remain domain controllers event logs, also dcdiag, repadmin tools can be helpful. If demotion does not go cleanly you can also perform metadata cleanup to remove it from active directory.
https://learn.microsoft.com/en-us/windows-server/identity/ad-ds/deploy/ad-ds-metadata-cleanup
https://techcommunity.microsoft.com/t5/itops-talk-blog/step-by-step-manually-removing-a-domain-controller-server/ba-p/280564
--please don't forget to Accept as answer if the reply is helpful--