I had issues with having incorrect URI schemes in use in sitemap.xml file.
I've found multiple issues about this topic. Some of people are trying to make it always use HTTP and some of people wants to use HTTPS only. In my case, I want it to be HTTPS always.
Here couple of the issues I've found:
This feature could be implemented as a setting in advanced settings (select dropdown). Where you could choose: 'default', 'http' or 'https'. This setting could be used when generating the URL to sitemap.