Government is necessary because human beings aren't angels. Almost everyone is a mixture of good and bad, and, one could argue, it's the bad side of human nature that needs to be restrained by the power of government. Otherwise, there'd be complete anarchy, with the strong dominating the weak, the evil exploiting the good, and a regression to the kind of primitive existence led by humans in their prehistoric state. Without government, everyone would be able to do as they pleased, with potentially disastrous consequences.
Government is also needed to arrange the life of a community along strategic lines. Even the smallest community needs to plan for the future. But, as everyone tends to be concerned with their own business, it's impossible for individuals, either alone or in small groups, to develop the kind of strategic overview necessary to plan ahead for vital social needs such as transportation infrastructure, national defense, and disease control. Only government, in whatever shape or form it takes, has the ability to do this.
Additionally, only government can carry out certain functions whose fulfillment is a necessary precondition for the operation of any society worthy of the name. As well as national defense, which we've already mentioned, governments exist to provide a system of justice, as well as a police force capable (at least in theory) of maintaining order and stability through fighting crime.