How to remotely change iCloud settings on iPhone 5?
Remove it from Find My iPhone via the web  


https://www.icloud.com/#find


At that point, iTunes will be willing to erase the device and/or restore it. You could also use Apple Configurator 2 which has a command line option to wipe devices:

cfgutil restore