So to get it from global configuration set in configuration.php from anywhere within Joomla component, plugins, modules and templates you would use:
$config = JFactory::getConfig();
$siteName = $config->get('sitename', 'No Site Name Specified');
$siteName = JFactory::getConfig()->get('sitename', 'No Site Name Specified');
You can also use name ...
I'm not sure if it will solve the problem but it seems like you downloaded an outdated version of VirtueMart. Please, try downloading this one directly from Joomla Extensions: https://extensions.joomla.org/https://extensions.joomla.org/extension/virtuemart/
Last update was June 18, 2020. Version: 3.8.4