Self-consistent approach for mapping interacting systems in continuous space to lattice models