How can I restore the previous system state after formatting my Macintosh HD? I tried to fix my MacBook Pro with Yosemite because it was always stuck on the Apple logo. I've never been in the boot menu and when I tried to open the Disk Utility to repair and verify, the result was the HD can't be repaired and fixed.

Next I tried to erase my Macintosh HD which had 250 GB used space but now is back to having 500 GB total free space. I know my files in Macintosh HD are deleted and I forgot to back up files to my external HD.

Now my MacBook Pro gets stuck on the prohibited sign logo whenever I try to boot it.

Is there any possible way to recover my previous files that I deleted using Disk Utility, after I reinstall macOS? Is there any way to fix this?

Or, would going to the Apple Centre be an option, as it takes me a long time to get there since I work on a tanker ship.
First, recovering your files may be impossible. You should immediately stop using the disk. The data may still be there, but marked as free for storing other files, so the longer you use the disk, the more likely it is that something will get overwritten by chance. There are services you can buy that will try to recover what's on your disk.

Once you get that sorted out, regarding the boot problem:

According to this Apple Support article, it means the computer couldn't find a valid system folder to boot from. Try starting in Recovery Mode by holding ⌘R.