You can't! What you can do though is use "Do Not Disturb" feature to silence your phone and only have your phone notify you when you receive calls from people you want. You will still receive calls from others.
if the same number calls, create a contact with that number and use a ring tone of silent. I use it for repeated calls that I can't block - the scammers who robocall. I have contacts named "do not answer 1" "do not answer 2". it's easy to find a ring tone of silence.
A lot of carriers offer these kind of features these days, so that might be one way to go.
Would be nice if there was at least an app for that, so to say...and there might be one, like Mr. Number or something similar perhaps (haven't really looked too deeply into it before).