I don't think it'd increase meaningfully
This is effectively having slightly better luck on one die roll. We don't increase monster CR because you manage to roll high a few times, yet effectively this is no better than a guaranteed high roll.
Unless one of the following is true, I would not change CR for the monster at all:
- The monster has a high-damage, single-use ability that it will probably use this effect on. (In which case, change that ability to simply not require an attack roll and base CR on that)
- The monster has extremely high damage, very low accuracy attacks (in which case, update that power to be usable only once and not require an attack roll and base CR on that)
Beyond that, it's not going to make a noticeable difference compared to what the luck of the dice is already doing.
Let's consider a different question for a moment. Suppose I'm building a monster, and I give it a melee greatsword attack with +4 to hit and 2d6+4 damage. How much CR does that add?
Well, it depends. If my monster was a huge dragon and it already had a bite attack that's way better than the greatsword, then the greatsword never gets used and it adds no CR at all.
On the other hand, if my monster was a ratling and its previous best attack was a dagger for 1d4+1, then the greatsword is actually a big deal.
So the answer I'd propose is: if you add an attack which the monster is going to use as its primary attack, you don't "add" to the Offensive Challenge for that. What you do is you figure out the Offensive Challenge for that attack, and you have just set the monster's Offensive Challenge to that number.
So: what is the Offensive Challenge of a petrification attack? What other monsters can we find that have petrification attacks, and what is their Offensive Challenge?
The basilisk has a similar power, except it's attached to a Constitution saving throw, DC 12. This power is the basilisk's most dangerous attack, so the Offensive Challenge of the attack should be about the same as the CR of the basilisk. The basilisk is CR 3, which, uh, seems kind of low actually for a save-or-die attack. The CR for your power might be lower still, since it requires an action to use and only affects one target at a time.
The medusa also has this power, except in the medusa's case the power is DC 14 and the CR is 6. Maybe we could make sense of this by saying that adding +2 to the DC means +2 to the CR, and the medusa also has a snake hair attack which is pretty dangerous, so maybe that increases the CR by 1 since the medusa can do both at once.
So I think the answer to your question will depend on the DC of the ability.
If I could add a note, as well: in my experience, fighting monsters with save-or-die attacks is frequently not fun. Either the player character makes the save and the monster's attack does nothing, or the player character fails the save and now that player is out of the game. You might consider replacing the save-or-die with something that does (for example) ability damage.
Best Answer
Here's how we can get the (existing) Flesh Golem's stats:
+7 to hit:
+3 proficiency, +4 STR. You know the flesh golem's proficiency bonus is +3 because it's a CR5 monster; you look this up on the table "Proficiency Bonus by Challenge Rating" on MM p.8.
2d8+4 bludgeoning damage:
+4 STR, the 2d8 is the golem's natural "weapon", its fists. That die type/number is not tabulated anywhere--it's one dial you can tweak for damage when trying to create your monster's offense.
You can find much excellent advice on creating custom monsters in Angry GM's Monster Building 101/201/202 articles. Be warned that his writing, while full of good advice and wisdom, is liberally sprinkled with rude and vulgar language.
You may have noticed that CR -> proficiency bonus -> damage -> offensive CR -> ... CR? Yes, there is a feedback loop in there. Angry GM's walkthroughs on creating monsters do a very good job of explaining things like this, pointing us to where the actual dials are that one can tweak.