This is mostly about probabilities and psychology.
Let's do a thought experiment. Suppose 100 helmet-wearing cyclists and 100 non-helmet-wearing cyclists crash. How many survive?
I made the numbers up, this isn't from any official statistics, but you get the idea. Now, one of the surviving cyclists wants to know what the chances are he was saved by his helmet.
This guy is not part of the 10 who died wearing the helmet, so that part of the sample is not considered. Among the 90 survivors who wore a helmet, 70 would have survived anyway without it. However, the difference is in the 20 (30-10) who would die if they didn't wear it, but stay alive if they did wear it.
Therefore, knowing that he was wearing a helmet and survived, the probability of his life being saved by the helmet is 20/(70+20) = about 22%.
The other question, "knowing that he survived, what is the probability he was wearing a helmet" would be 90/(70+90) = 56.2%, which is quite close enough to random in this case.
To illustrate the influence of the "treatment effect size", let's use a life jacket instead of a helmet. It is not very effective while crashing on a bike, so it only saved one guy who fell off a bridge into a lake.
In this case, on any random crash, the probability that the guy was saved by the life jacket is only 1.4%.
On the other side, the usual example is the parachute. There is always a story about one guy with freakish luck who survives jumping off a plane without a parachute, but that doesn't change the results very much.
Please ignore the fact you can actually know if the helmet saved your brain by examining it after the crash. It was just for the sake of using a non hysterically politicized example.
You can do the math with the actual covid data, though. You can get any result from "parachute" to "life jacket on a bicycle" depending on your friend's age and comorbidities, and also the variant of the day of course.
Your friend isn't using logic, he is simply exhibiting commitment-driven rationalization. So this isn't about philosophy and logic, rather about math (above) and psychology (below).
When humans commit to a costly action, they tend to rationalize after the fact that it was the right thing to do. This can take many forms, and it has pros and cons. It can soothe anxiety about having made the right choice, and make one happier about the choice made, however it makes one more prone to the sunk cost fallacy (among others).
Consider a cancer patient. The operation is successful and the tumor is removed, but there could be a tiny clump of cells remaining somewhere that wouldn't show up on a scan. If you want to know if it's there, you have to wait for it to grow enough so it shows up, which is not a good idea. So the patient is given chemo, loses his hair, and gets all sorts of nasty side effects. If the patient is cured, then it is impossible to know if there was actually some cancer left and the chemo destroyed it, or if there was none and he lost his hair for nothing. There is only probabilities, "we know that the patients who didn't get chemo died X% more". However, after spending six weeks throwing up, most people will forget all about the probabilities, and rationalize until they're absolutely convinced that it was 100% necessary. Can't blame them, and it makes the ordeal much more bearable. In fact, it would be quite rude to remind them that maybe they lost their hair for nothing, even if it is true.
The vax doesn't score very high on commitment (as long as you don't look too much into the side effects). However, it brings another type of commitment, of the tribal kind. Consider a hardcore football supporter: their team is the best, even when they lose, and you will never change their mind. Now, due to a tsunami of propaganda, we definitely have two teams/tribes: team Vax and team Unvax, who suitably blame each other for the mess we're in and fling poo at each other on twitter from the trenches they've dug. And they're quite firmly dug in and really stubborn. Therefore, I think an important and often neglected part of vax commitment is one of allegiance to a tribe.
This one is tough because it is very strong, and truth becomes completely irrelevant: it's pretty much "we eat the eggs from the big end, and the other guys we're at war with eat their eggs from the little end, those filthy heretics!" In these matters, whether the vax works or not is irrelevant. In fact, you will get more commitment (and therefore more rationalization) if it doesn't work at all, preferably with nasty side effects, because then you have to really believe it works in order to do it. Then it becomes like a ritual for the purpose of reinforcing belief. I would recommend reading about Festinger's experiment, "When prophecy fails".
So it is possible that your friend associates questioning the efficacy of the Holy Product with betrayal against their tribe, or even heresy. You're not going to logic your way out of this one.