Surface enhanced Raman scattering in the presence of multilayer dielectric structures