I'd thought I would take a moment to clarify what you mean above.
Using a default index page or using a redirect will never indicate to a robot that the resource is "404 Not Found" or "403 Forbidden" or any other error code because those two methods issue their own status codes: "200 OK" and "302 Found" respectively.
If you use ErrorDocument directive with a local URI or string it will preserve the status code and allow for you to customize the page content. This plays nice with robots and allows you to inform humans in a friendly manner of what happened.
Not to forget that Internet Explorer will show its own error pages unless yours is at least 512 bytes.
Perl / MySQL / HTML+CSS