Slavery first began when powerful individuals, with the force of arms, guarded their surplus food storage so that only they could access them, whereas before, surplus food storage was considered communal property that everybody had an equal share to.
Now let's put ourselves in the shoes of such a powerful, wealthy individual with a guarded, private food surplus that only he can access. The land around him needs to be tilled and worked, and he needs to "hire" workers who will do that for him. In exchange for the workers' labor, he gives them enough of his surplus food storage to survive. There would be no reason for him to give his laborers any more than the bare minimum, and so the laborers were always on the edge of starvation - if their master refused to employ them, then they would die of starvation.
We see that there are two options - work for the master and get barely enough to eat, or don't work for the master, have no access to food, and die. A strong man alone could go off on his own and create his own farmland, but if he did so, he would be vulnerable from other such opportunistic men who would seize his newfound land unless he had an army to protect himself. An option would be for a group of men who would agree to protect each other from squatters and invaders. Families had no choice - women and children couldn't survive under such conditions, so they were forced to go into slavery. The children of the first generation of slaves would have nowhere else to go, for their master was the only source of food. Thus, slavery became hereditary, and the master-slave relationship was born, and would last for millennia.
The unfortunate thing is that there is no incentive to pay a slave more than the subsistence wage - that is enough food to barely survive. Slaves were in very high supply, and their population was always increasing, so the price for their labor never would go up. Pretty much, it goes like this, even in modern times: if you have lots of choices, you are more free; if you have little or no choices, then you are more toward the slave end of the spectrum.
Slavery became institutionalized as time passed because religion and supernatural forces condoned it, and soon, it never came to the mind of slaves that their condition was at all unjust or brutal - both the slaves and their masters accepted their status of birth without undue question, for every day reality of survival, reproduction, work, religious rituals, and sleep dominated their lives. When one does not have free time to contemplate, notions of freedom, fairness, and equality are nonsensical, and immediate practical needs dominate. Soon enough, slavery became a way of life.
It's all a matter of basic economics. The law of supply and demand breaks down when you don't have free markets. Individuals are forced to supply their labor for free, whereas today we supply our labor, and we get paid a market value for it. Most people today have a choice of work for company A vs. company B, work for free (volunteer), etc. Essentially, masters gave the to-be slaves one choice - work for free, or die. And because anything was better than death, the to-be slaves were forced to work, and thus became slaves.