It is theorized that every animal on Earth has evolved into its present state through adaptations and mutations linked to the survival of the species in certain habitats. Cows and many other female mammals have benefitted from an anatomical structure called an udder. The “boob” you refer to is actually the udder.
Cows are mammals, just as humans. The two factors that determine what can be labeled a mammal are giving birth to live young, as opposed to eggs, and nourishing their young with milk produced by mammary glands in the female. One of the features of mammary glands, like many other organs, is that they come in pairs. Human females, obviously, have a single pair of mammary glands, which are separated by skin that forms the cleavage between the two breasts. Attached to each mammary gland and, subsequently, each breast are two nipples, from which the milk can emerge.
Cows also have mammary glands in pairs, except that cows have two pairs of mammary glands with a nipple attached to each. This means that a normal cow has four nipples and not five as you suggest. This doesn’t mean that some cows don’t have five nipples, but those that do are freaks of nature with an errant extra nipple. A cow with five nipples is like a human female with three nipples. It is possible, but definitely not normal. What is more common in cows is to have an extra pair of vestigial nipples, making six. Usually these extra nipples are much smaller than the four main nipples and they do not produce milk.
As for the cow’s udder, yes, it can be described as a boob, but inside the single udder are the four mammary glands. It is unknown why each mammary gland does not have its own breast like humans, but some scientists claim it has to do with efficiency and body heat. Cows are not the only animals to have multiple mammary glands in a single udder. Deer, sheep, and goats also have udders, except those animals have only two mammary glands in their udders and two nipples protruding from it.