I have not played around with it but these pages are based on the apache velocity project (https://velocity.apache.org/)
So check out those pages on how to create a template.
I'm running into the same issue….How to change the Mendix-Logo in de SSO-error page (SAML20-module).
I did looked to the Velocity-project...but I did not find a clue overthere…. :(
Does anybody knows how to change that default Mendix-image?