I know that the negative prefix im- is used before b, m, p as an assimilation of the prefix in-. Then why can't we say imbelievable, inpleasant or inpredictable but we use unbelievable, unpleasant and unpredictable?
While there is no way of discovering a simple explanation, we can at least look at the linguistic forces that worked on the English language. The prefix -un comes to us from Old English, which was (in the mellifluous words or the OED) "freely applied with a purely negative force." Words that come to us from Old English, (like belief from the Old English gelefan, to believe) and that had un- freely applied to them are likely to retain the form. The OED finds a use of unbelieved from the year 1200. Likewise, words that come to us directly from Latin are likely to retain the Latin negatives im- and in-: for instance impotent from the Latin *impotencia, which comes to us with the negative already implanted.
This neat dichotomy is disrupted by two things. The first is that we get many words of ultimate Latin origin via Old French, which brought the Latin negative with the Norman Conquest. Pleasant comes to us from Old French pleisant, and although we never said impleasant, we once (although rarely) said impleasing (from 1602) and unpleasing (from 1680).
The second disrupter is that sometimes some words that came to us directly form Latin (e.g., predict from the Latin praedicere, to foretell, ultimately pre-, before + dicere, to say) arrived without a commonly-used negative. Here we have only the rarely used impredicable first found in use in 1623. The forms predictable and unpredictable arrived in 1857.
I'm afraid that the best we can do is descriptive rather than explicative. The OED tells us that starting in the 14th century, both the Latinate im-/in- thrived along with the "native un-," with preference for the former only in cases of words of clearly Latin character. (The OED cites inadequate, inadvertence, and inarticulate.) The golden age of "doublets" lasted until the 17th century, when people started to choose one form and discard the other. The 18th and 19th centuries saw un- become increasingly the popular choice no matter what a word's etymology had to say. (See predict above.)
It's not that the native prefix always prevailed. The OED has first uses of impossible and unpossible in the 1300s, with the latter "very popular 1200-1400. (Possible is from the Old French posible.) But it's impossible today to use unpossible in any but a jocular sense.
Two people have given it as comments, but I will give it as an answer, because that is all the answer you'll get to a "why" question:
Because that is the way it is.
There is a bit of historical information you can add to help understand it, which is that impossible was borrowed from French, and already had the Latin prefix in-, whereas unpleasant was formed within English from the French loanword pleasant. But there's no reason "why" this should have happened, and no way that you can work it out except by knowing the words.