Retaining data in local storage

We are currently creating an app for one device and one account.
How can I do that?
I had identified it with a device token, but when I update the app, the device token gets updated.
Also, in the case of IOS, you can’t create UUIDs and keep them in local storage storage because local storage data also disappears when you update the app.
Android didn’t lose the data in local storage after updating the app.
Is there any way to save the data saved on the device that won’t be lost when I update the app?

I’m Japanese, so I’m using DeepL to translate, so please forgive me if some of the text is strange.