Yes, you can set up Basic authentication on a per-domain basis. Please refer to the following article for more details. Basic authentication