If you're building muscle, you will gain weight. Muscle weighs more than fat. While you build your endurance (and consequently muscle), you still need to diet lightly to keep the fat off.