The most common reason for a buzzing sound when you play a chord on a guitar is that the strings are not being "fretted" properly. That means you're likely not pressing down hard enough on the strings on your fret hand. It may also mean that you're pressing down on a string too far away from the actual fret. Make sure your nails are trimmed low and you're using the top pads of your fingers on each string you're trying to press. Press down hard and make sure you're not accidentally touching any of the strings you're not supposed to fret.