Before removing a HomeKit door lock that has been added to the Home app, ensure that the lock is properly connected to HomeKit (you can try locking and unlocking it using the Home app to check). If you remove the lock while it is not connected, it may become undetectable by HomeKit later on. If this happens by mistake, you will need to reset the lock to its factory settings and then reconnect and rebind it to the Home app.