Follow the guide below to upgrade your PBX to SP6. Then perform a full backup of the system and save it a non 3CX location.
Un-install the system and re-install V16. Restore your backup during the installation. https://www.3cx.com/blog/news/pbx-upgrade-update-6/
Is there no way to do an in-place upgrade from SP6? You have to backup, uninstall v15, then install v16 with the backup? Is that the only migration path?