The error seems to indicate that you're trying to add a device to a deleted user, which would obviously fail.
I am trying to add inside an admin user, I think it should work normally. I cannot find where it is specified for which user I am creating the device.
What kind of admin user? Service account?
YES, an admin type account
Please carefully read my question. You have not answered it.
I created a user, which I gave admin privileges to. Within that user I add new devices, but from today that error appears.
OK, so it's a admin, but not a service account admin. Then I don't know how you got to this situation.
I am trying to add a new device but I am getting this error.
Yesterday everything was working normally, but after deleting a user this error occurred.