By default, Magento redirects to the base URL so that's the reason why when you try to access the second Magento application, it gets redirected.
For this perfect scenario only, Magento has features like multiple websites with single Magento instance. Please create another website, store and store view from Magento admin panel and change the second website URL to the second new domain you purchased. You should also add few lines of code in the index.php file for this to work. Please refer to my index.php below:
$params = $_SERVER;
$domain2store = array(
'xyz.com'=>'base',
'www.xyz.com'=>'base',
'abc.com'=>'apple_website',
'www.abc.com'=>'apple_website',
);
if(isset($domain2store[$_SERVER['HTTP_HOST']]))
$storecode = $domain2store[$_SERVER['HTTP_HOST']];
$params[\Magento\Store\Model\StoreManager::PARAM_RUN_CODE] = isset($storecode) ? $storecode : '';
$params[\Magento\Store\Model\StoreManager::PARAM_RUN_TYPE] = 'website';
$bootstrap = \Magento\Framework\App\Bootstrap::create(BP, $params);
/** @var \Magento\Framework\App\Http $app */
$app = $bootstrap->createApplication(\Magento\Framework\App\Http::class);
$bootstrap->run($app);
After all, please do a static content deployment and refresh the cache. You are set. I hope this helps.