The exception seems to be monsters created with the DMG rules. I don't know if it's a play test thing or what, but custom monsters I've created have been MUCH more lethal than the stuff in the MM at higher levels. I actually much prefer them.
The DMG custom monster rules are very exploitable. It's trivial to create a CR 1/4 creature that can kill Frost Giants with ease. Here are some things that are "free" for a CR 1/4 monster:
Arbitrarily high movement
Teleportation
Ranged attacks as long as they don't deal more than 8 damage on average
An arbitrarily high number of Legendary Resistances
Immunities to an arbitrary number of conditions (exhausted/charmed/stunned/etc.)
Immunity to fire/cold/force/blunt/piercing/slashing/magical weapons/etc., as long as you halve HP to compensate
Arbitrarily high ability scores, as long as they don't increase damage dealt or total HP (INT 24, WIS 24, CHA 24, CON 24 as long as you give it a small base HD)
I forget whether you can get spell immunity for free as well, but 50 Legendary Resistances is pretty sweet already.
In short, the DMG rules are okay-ish as a formula for telling you how much experience a given creature is worth, since you gotta have
something, but they're quite bad at telling you how genuinely dangerous a creature with special abilities is. If you create a custom monster, and it isn't just a sack of HP with a melee attack--suppose that it has a ranged Entangling attack and can teleport as a bonus action to snatch entangled prey--it's guaranteed that the DMG guidelines will underestimate its lethality.
On the plus side, the DMG encounter balancing guidelines already underestimate PCs' (potential) lethality, so tricksy monsters against tricksy PCs might actually be a fair match.
As an aside: one of the best advantages a monster can have is looking so much like a weaker monster that it gets underestimated. In my world, PCs benefit from this constantly. They look just like regular, weak old humans. A squad of 12 hobgoblins doesn't run away from three PCs when they see them coming because
the hobgoblins assume they will win! If hobgoblins have been warned by the survivor of a previous battle, or if the PC Necromancer raises an army of skeletons, this ceases to be true, and the hobgoblin squad takes the threat as seriously as an enemy platoon (break contact, skirmish at range while waiting for reinforcements to arrive in force--all the things that frustrate PCs).