It sounds like the limit screws are set incorrectly and the friction/index levers may need to have the friction increased. If you're not an experienced bike mechanic you should probably take it to a shop since it is easy to misadjust things and drop a chain to the inside between your cogs and the wheel and cut the spokes.