When your website is under maintenance then you can place the app_offline.htm page in the root folder so that any user access the website(any page) they will get the app_offline.htm page.
When you have custom redirects for httpErrors in your website, you may get the message "The service is unavailable" message when you place the app_offline.htm page in your website. To resolve this issue just add the below configuration in your web.config file under httpErrors section.
<httpErrors errorMode="Custom" existingResponse="Replace">
<error statusCode="503" path="App_Offline.htm" responseMode="File" />