I'm glad you asked (im a medic main, and this is gonna be a long one), so here are my 3 (sacred) tips to improving as medic:
1) analyze you're own game play WHILE your playing, and if you have time record it and watch after, and you may be wondering how do I analyze while i'm playing? when you die, don't get mad or blame someone else, don't just wait to respawn, notice how you died, was it truly unlucky that the scout that killed you knew where you were at the exact moment and the exact time?, no. and when people die, they will just say Oh he's better than me even if he is better than you, analyze what he did better than you and see why he was able to kill you, this may seem boring but when you do it constantly, you improve your game sense a lot, (and game sense is important as medic) and also watch other youtubers and see how they play and what they do at certain situations.
2) Surviving as medic this is probably the hardest thing to learn, LUV mentioned 2 points, which is stay out of sniper sight lines and watch your back at all times. and he is correct, but, HOW do you do it you ask? let me explain, first of all, THIS will be very hard as medic and this is also where game sense MAJORLY kicks in, knowing when you get ambushed and how to avoid it is all part of being a medic, and although I cannot tell you how to practice game sense (because game sense is something you can't explain but understand with experience), but I can help you improve on it. So my biggest tip for this is. manage your positioning and if possible, alarm your teammates, knowing where a sniper can and can't shoot is a major advantage against him, and knowing how SKILLED the opposing sniper is, will help you know if you can take a risk or not, if he's relatively bad, then you can take the risk, if he's a god, then you may need to do some strafing to arrive at your location. and this also applies with spy's too, know where the enemy spy can attack from and which route he'll take, so you can escape or attack, though as I said, if he's skilled, don't attack, if he's not, i'd suggest running but you can still attack if you want to. SO so surviving as medic can be tough, and hard to master, so have patience.
3) (and this is a mistake I made) STAY CALM AT ALL SITUATIONS this one is obvious but applies most to medic, never EVER panic as medic, panicking will be either the loss of you, your teammate or both, panicking as medic is basically opening a door to your death, and as a human, it is very easy to panic, so attempt to stay calm AT ALL SITUATIONS, and this one is quite short but EXTREMELY important, so DON'T PANIC.
Anyways, those were my 3 tips to medic, hope this helps, you out, and remember you WILL go through times as medic where you want to kill your self, but hey, that's part of the experience, so go out there and help the team, YOUR the hero of your team, and YOUR the decider between victory and death for your team.