csrutil disable
Restart computer
In the terminal, type
sudo open /Applications/TextEdit.app /System/Library/LaunchDaemons/com.apple.ManagedClient.enroll.plist
change
<key>com.apple.ManagedClient.enroll</key>
<true/>
to
<key>com.apple.ManagedClient.enroll</key>
<false/>
So that the changes take effect
Watch the video.
https://www.youtube.com/watch?v=khlALitW0zI
Use skipmdm.com. There are instructions on the site. It will create an account and run a script to block the appropriate IP addresses and bypass the enrollment page. At the desktop delete the Apple user account created by the script.