How to use multiple 404 Error Pages in WordPress

Thank you guys for the help and the tips.
@Dexter0015 Tip helped me in the end to get it done.

This is how my 404.php looks like now im only checking if in the url the string is present and show the template for it.

Thanks everyone again

edit:

i changed the search values to /services/ and /blog/ so it was a bit better when the url has services inside or something it got messed up now it works perfectly for me

$postUrl="http" . (isset($_SERVER['HTTPS']) ? 's' : '') . '://' . "{$_SERVER['HTTP_HOST']}{$_SERVER['REQUEST_URI']}";

get_header();



if (strpos($postUrl,'/services/') !== false) {
    get_template_part("error-pages/services-error-page");
} elseif(strpos($postUrl,'/blog/') !== false) {

    get_template_part("error-pages/blog-post-error");

}else{
    get_template_part("error-pages/general-404-error");
}




get_footer();