If you have 18GA wire between the circuit breaker and the doorbell transformer, then you have a fire hazard. Replace the 18GA wire with standard 14 gauge wire attached to a 15A breaker.
18GA wire on the low voltage side of the doorbell transformer isn't a problem as long as the transformer is fused.
Your wire gauge issue probably isn't related to the buzzing breaker. You can rule this out by attaching the doorbell wire to another 15A breaker in the panel. If the other breaker doesn't buzz, then the wiring has nothing to do with the buzzing breaker.
The buzzing breaker may be defective or loose. Try reseating the breaker in the panel. If that doesn't help, replace the breaker. If replacing the breaker doesn't help, your panel may be damaged. If the panel is damaged, call an electrician.