Carbohydrates add glycogen to the muscle which stores with water. If you’ve been
Relatively low carb and then eat a little bit of carbs, you’ll gain weight rapidly, but it’s mostly water (initially, until you’ve eaten 2 entire loafs of bread because you missed being happy and overdo it - then you’re in a surplus and adding fat).