Exactly, all healthcare systems must engage in triage of some sort becasue resources are not unlimited. For example in the case of the 80-year old McCain and the very poor prognosis of a glioblastoma, only palliative care would probably be done under the UK’s NHS - so that resources can be better be used to try to save a younger person and/or a more treatable condition.
But in the USA, unique in the industrial world, that triage is based on the wealth and social status of the sick person. Recently, the 90 year old Jimmy Carter was saved from normally terminal metastatic melanoma in his brain by a new experimental treatment. But this treatment would have almost certainly been unavailable to young, poor USAn without insurance - or maybe even with insurance.
Some brave people - out of solidarity with the poor working class, have foregone very expensive life saving treatments. I recall that the folk singer Utah Phillips dying of heart failure was a good candidate and apparently had the insurance for a heart transplant. He turned it down. He figured that at the age of 73, he had lived a fulfilling life making sure that Joe Hill had never died.