I think it’s worth reiterating just in case: if this is a relatively new install, it would be better/easier to reinstall Nextcloud using the new storage directory as opposed to changing the existing path. Here’s some more information about how to proceed: Is there a safe and reliable way to move data directory out of web root?
Edit: Actually this is probably a better link: HowTo: Change / Move data directory after installation
I have done this successfully, but it’s technically not supported or recommend by Nextcloud.