If you manually set a key on an IP Phone it will most likely get overwritten once the device reprovisions via 3CX. As @JohnS_3CX has already mentioned, here: https://www.3cx.com/community/threads/blf-settings-are-overwritten.80720/
you can avoid this from happening by removing the provisioning link from the phone. Alternatively you could also accomplish this using a custom template which of course is not supported by 3CX.