Foods that traditionally cause water retention are:
Dairy. If you normally eat dairy, you may or may not notice this.
Higher carb foods (hydrate means hold onto water so...). If you normally eat more carbs, you may or may not notice this.
and if you eat low carb, its not water retention but glucogen that is in your cells are depleted, when you eat a higher carb meal, that glucogen is added back causing a weight gain although it wouldn't cause any bloating that you might get from water retention.
Water retention isn't necessarily a bad thing considering our bodies are 70%+ water but it just may cause you alarm as you see the scale fluctuate but that is normal.
You can't out-exercise poor eating habits.