Sacred flame isn't the greatest cantrip, because it only hits if the target fails a DEX saving throw. Lots of creatures will have at least a decent DEX, while also might having proficiency in DEX saving throws. This means they will roll a d20 with maybe a +5 to beat your Spell save DC, which as a cleric will be 8 + Proficiency + WIS modifier(which will only be 13-14 in EA.) Spell save attacks are hard to land in the earlier levels, but as you level up, your Spell save DC will increase which can make it more accurate against high AC enemies than attacks sometimes.
The early weakness of Spell Save spells are highlighted in BG3 vs 5e, because everyone and their grandma can get advantage on attack rolls, and spell saves don't get any bonuses from that.
If you aren't landing any hits on Sacred flame though, you need to make sure you start with a 16 in wisdom. Clerics are full casters, so unless you are going for a purposefully awkward build, you will want to max your spellcasting score.