The development of arbitrary morphological classification results from innumerable factors that obscure the relationship between form and function. For example, there may be a sound change that developed in the language that raises word-final mid vowels. Roots might arbitrarily end with /i/ vs. /e/, and there could be a rule of palatalization where /k/ → [č] / __ i. With the addition of the final vowel raising rule, you can get new sequences like [muki] which don't undergo that rule (because originally they were [muke]). Inflectional classes of this type then result from the impossibility of knowing (without doing the historical reconstruction) which words had /e/ and which had /i/, and thus which behave one way vs. another.
There are non-phonological causes as well, where an inflectional affix only combines with a certain semantically-defined class of verbs (e.g. a perfective affix only combines with stative verbs). New stative verbs may be added to the language, and yet don't allow that affix (perhaps because they are basaed on a noun) -- thus you have verb classes where you have to sort roots as to allowing vs. not allowing this affix -- conjugation classes.
In short, the basic reason is that the relationship between form and function is not always self-evident, and therefore it may be easier or necessary to treat the relation as a somewhat arbitrary list.