DigitalOcean provides a barebones solution (VPS / Virtual Private Server), which allows you to create essentially anything you’d like.
You’re provided with a blank canvas and root access to your Droplet (VPS), so you’d be free to install any software that is capable of running on the operating system you choose – that includes PHP and MySQL.
If you’re not too familiar with the CLI (Command Line Interface), you may want to check out the link below. DigitalOcean has a growing library of tutorials that cover a wide range of topics, including setting up a LAMP (Linux, Apache, MySQL, PHP) or LEMP Stack (Linux, NGINX, MySQL, PHP-FPM).
DigitalOcean Tutorials: https://www.digitalocean.com/community/tutorials
As far as your application, you mention allowing both online and offline access. Accessing the VPS does require online access, so if they client using your application goes offline, they wouldn’t be able to access the server which your code runs on. You could, of course, run your code locally and set that up for the client and then when they go online, have it sync, though that’s something you’d need to setup at the application level and on the client side.