If you have multiple websites within one Magento installation and want to restrict the customers for using the same customer account information for all the website, what you can simply do is to configure customer account scope in Magento 2.
For more information visit, https://meetanshi.com/blog/configure-customer-account-scope-in-magento-2/