Buyback for wealthy pos-1 or pos-2 is significantly different from support’s one. It’s not necessary to use BB before the late game stage (30+ min), except for the situation when your team is securing Roshan spawn or defending Throne. Frequently you will not restore burned money, even if you kill 2-3 heroes after respawn, and in case of death after the BB, you also lose more than 90-110 seconds so that the opponent can outdistance you in the networth and experience.
The late game starts at approximately 30:00 minute when your carry/mid has three or four key slots in stash, and the opponent can already demolish Tier2\3 towers and push high ground. Generally, everyone in both Dire and Radiant teams always “must have” BB in the late game, but there are exceptions here too. Firstly, buyback does not make sense para heroes without key spells, for example, Phoenix, Enigma, or Wraith King. You’ll just be like a whipping boy for enemies, and they won't have a problem doubling your death score. Secondly, it’s unreasonable to buyback if your crucial artifacts are on cooldown. Most often, this item is BKB: if the enemies have a lot of magic damage and control, then two of your entries into the fight without BKB will be several times less effective than one burst with it.
Buyback is more important than any damage item, except Divine Rapier. This item allows you to go “all-in”, so you can spend all your gold because in case of its drop, the odds to win are minimal. Thirdly, heroes who press global ults at the beginning of the fight and cannot survive anyway may also forget about buyback. This applies to Terrorblade, Sven, Lycanthrope, and Lone Druid. At the same time, such personages still leave gold for BB if the opponent has a chance to instantly kill you (Legion Commander, Lina, Lion, Tinker).
In other situations, leaving a buyback is incredibly important. Even if one team overfarm’s the other by 20-30k gold, in the late game, they will have zero odds to storm Tier 3 tower if the opponent defends in the high ground with buybacks. More often than not, Pro players exploit fake-trick attacks to force buyback, but in many situations, it is better to lose barracks than to use BB. If your rich core buybacks, he will have 8 minutes BB cooldown, while the opponent still has two lives - a huge advantage.
Buyback options para supports/offlaners cheaper due to their low networth rate and level, and there are no problems with their respawn timer. Therefore, the BB restrictions on these roles are not so strict. For example, supports can use BB in the early and mid-game 2-3 times to secure Roshan and Tier-3 tower plus barracks, as well as to protect Tier-1 mid tower or to save ally core, set wards, or capturing Outpost. Ideally, you can manage it during a good fight, but in some cases, you can BB before the fight to force the opponent to move away. It is super principal to use BB into fights if the support has an important team fight spell\ult that he didn’t press to death, for example, Echo Slam or Winter's Curse.