You can of course upgrade to Mojave, How to upgrade to macOS Mojave - Apple Support
Go to Section 4 and click on Get macOS Mojave. This will open the App Store at the Mojave
download page. Does this page say 'Get' or 'Open'. If it is saying 'Open' the App Store is detecting
a copy of Mojave on your mac. Look in your Applications folder for Install macOS Mojave.app,
if you find it move it to the Trash and empty the Trash.
Connect your mac to your router using a cabled connection. Restart your mac,
access the App Store Mojave page again and try downloading again.
Do not use the mac whilst it is downloading and do not use other devices that share the same
internet connection.
Before upgrading make a full back up of your Mac.
Check that third party apps you use have updates available for the new OS.
https://roaringapps.com
Check that your printers/ scanners etc have updated drivers and software available for the new OS.
If you are considering upgrading to Catalina be warned that it does not support 32bit apps.
Your Mac is probably running 32bit apps and these will need to be updated to 64bit apps,
some updates may be free, some may be paid. Use this app to discover which apps you have
are 32bit, https://www.stclairsoft.com/Go64/. Once the list has been created you can then
contact the developers of the apps to see if they provide 64bit updates.
How to upgrade to macOS Catalina – Apple Support