You should be able to leave the AD domain by going to System Configuration -> Active Directory, then in the Action menu in the upper right corner of the page (3 dots) choose Leave.
Then you should be able to change the hostname under System Configuration -> Networking (Action menu -> Edit)