Subfolders in nginx

I am trying to configure multiple grav sites as subfolders in nginx. I am working on Ubuntu and following the learn.getgrav Digital Ocean config tutorial and have successfully installed a single grav site with the basic ‘grav’ config file in /etc/nginx/sites-available

I am now trying to install multiple sites as subfolders. As a first attempt, I have installed another instance of grav in /home/grav/www/html/sysmanual/

Then, in the config file, after the server section, I added a subfolder section:

location /sysmanual/ {
root /pi
try_files $uri $uri/ /index.html;
if (!-e $request_filename){ rewrite ^(.*)$ /sysmanual/index.php last; }

However, when I go to localhost/ it does not work.

Can anybody say what I am doing wrong? Do I need to adjust the server section of the config?

I fixed this in the end by editing /etc/hosts
I changed the line: localhost
To: sysmanual policyman

This means I can go to http://sysmanual or http://policyman as they have been configured in sites available and sites enabled