Problem with old Shelly devices

Good morning. I have tried several times to install Shelly devices. Sometimes they worked well, sometimes they didn’t. But when I try to reinsert the Shelly unit, it often finds an IP address that was already taken from a previous component of the same brand and now no longer exists and reset. How can I delete these devices so that it does not tell me ‘Device already configured’? Thank you