Effect of collective and molecular modes on the thermalization and diffusion of neutrons in light and heavy water