There are apps available which will not only block individual numbers, but also callers who have withheld their number. You can also block calls from anyone not in your Contacts.
However, we have found that typically hospitals and doctors' surgeries when calling us withold their numbers, presumably because they do not want their direct line numbers made known to all and sundry, so there are drawbacks to using such things.