File Location:
/var/www/nextcloud/config/config.php
look for file locking location and choose true or false
$ file locking enabled -> [true,false]
Update
sudo php /var/www/nextcloud/config/config.php
Give config file ownership
sudo chown www-data:www-data /var/www/nextcloud/config/config.php
Might have to add these to config file
sudo nano /var/www/nextcloud/config/config.php
then
$ maintenance = false
$ config read only = false