You are probably confusing the step where it creates an installer app from a .pkg with actually installing.
Click on this link to read how to get different versions of macOS - https://support.apple.com/HT211683
- Sierra, El Capitan, and Yosemite download as a .pkg. Click on this to have a converted version placed in your Applications folder as an "Install OS..." application. Run the installer and follow the directions.
- Upgrades may take some time (up to an hour or more) to install, with restarts and blank screens.
Before upgrading, back up your data in case something goes wrong. See this support document: Back up your Mac with Time Machine - https://support.apple.com/HT201250 or use a cloning tool.
Check if your old apps will still work with with the OS you want to install - https://roaringapps.com/apps