How does Android handle APK apps data?

I have created an app using React Native and Expo, and I built it into an apk using EAS, I have installed it on my phone for debugging purposes and the such.

Anyways, I am using the Expo filesystem library to create files within the documentDirectory as Expo names it. My question is, if I make changes and rebuild the APK and reinstall it, will the data there be intact? Or will the install wipe it due to the new version? And if so, how do I make sure it will install it as a separate app? Will changing the package name work?

This is the Expo module I am using: https://docs.expo.dev/versions/latest/sdk/filesystem

I am using a Xiaomi phone running MIUI, which is built upon Android.

Thanks in advance for any answers.