How to change device name in Profile Manager
you can only change it if your devices are enrolled in supervised mode. use apple configurator 2 to enroll the device to MDM, then you can select the supervised mode option.

after it's successfully enrolled, you can then rename the devices via the profile manager.