The webhook URL will only change if you do persists the .n8n folder as that is where the webhook URL gets saved. Not persisting this folder will definitely cause problems. Especially will it also result in you not being able to decrypt your credentials after a restart.
You can find the topic of somebody else which had the same problem here:
Apart from that did “sadly” never hear before that n8n becomes stale. I also never experienced it myself. So no idea why that happens for you.