Influence of the dielectric substrate on the terahertz electric near-field of a hole in a metal