custom masterpage – Give Different Error pages for Variations site in Sharepoint 2016

I have a Web Applcation which contains a Publishing Site with Variations feature enabled. The following is an example URL for the site

I have enabled a custom error page for English Site. But I want to enable a new Custom Error page for Arabic site with the following URL

So overall there should be two Error pages one for Arabic and one for English. How do I go about it?