The bill goes to the government, who gets its funding from the people. This in no way stops any systemic over-billing that may be occuring.
On national health insurance (monthly cost depends on your salary but for an average person it is a few hundred bucks per month) the hospital pays 70% and patient pays 30%.
It means basic visits to the doctor or dentist are very cheap here. Like $20 for consultation + medicine. ER+X-rays and MRI (appendicitis, sigh) was a little bit over $100.