A special masters program (SMP) is often offered by a medical school and includes much of the coursework taken by medical students during the first year of medical school. It might be called an MS in Anatomy or an MS in Physiology. It determines if you have what it takes to do well in medical school where there might be doubts, based on past academic performance, that the student has what it takes to do well.
So, you pay something close to a year of med school tuition betting that you can out-perform most medical students at that school. If you do well, you may get an offer of admission to that school (sometimes, I think, called a "linkage") or you may apply to other medical schools with the hope that your high GPA in the SMP is evidence of your ability to rise above your poor undergraduate record and succeed in medical school. If you do poorly in a SMP, it is GAME OVER for your chances of going to medical school so it only makes sense to do a SMP if you have a poor undergrad record but believe that your undergrad record underestimated your ability to perform at a high level and that you can come out on top in a competitive class of medical students.
Keep asking questions. That's why we're here.