If you hear a clicking while pedaling, try shifting to a different gear as you pedal to see if the issue persists. If it does, you want to adjust your rear derailleur.

Take a look at the link below for a DIY how-to: https://www.parktool.com/blog/repair-help/rear-derailleur-adjustment.  If you have continued difficulty, any local bicycle shop can make this adjustment for you.