Binding of Two Helium Atoms in Confined Geometries. II. Dimerization on Flat Attractive Substrates