You're using only the way Israelites were commanded to behave toward other Israelites. And even then, I vey much doubt that it was just like working for someone; Israelites were to be freed in the 7th year unless he chose not to - such as wanting to keep his wife and child who belong to the slave owner.
Biblically slavery was part of the way people lived, took for granted, and believed was one of the practises ordained by God. Nowadays, of course, we are horrified by this (but only for the last 200 years).
For the people who wrote the Bible, enslaving others was part of their culture. The Bible explains that conquered peoples are to be enslaved (or just the virgins if all others are slain), other ways of enforced slavery, or people presenting themselves as slaves if they can't discharge debt. Here are just a few examples, including a couple from the New Testament:
Leviticus 25:44-46, "However, you may purchase male or female slaves from among the foreigners who live among you. You may also purchase the children of such resident foreigners, including those who have been born in your land. You may treat them as your property, passing them on to your children as a permanent inheritance. You may treat your slaves like this, but the people of Israel, your relatives, must never be treated this way."
Exodus 21:2-6, "If you buy a Hebrew slave, he is to serve for only six years. Set him free in the seventh year, and he will owe you nothing for his freedom. If he was single when he became your slave and then married afterward, only he will go free in the seventh year. But if he was married before he became a slave, then his wife will be freed with him. If his master gave him a wife while he was a slave, and they had sons or daughters, then the man will be free in the seventh year, but his wife and children will still belong to his master. But the slave may plainly declare, 'I love my master, my wife, and my children. I would rather not go free.' If he does this, his master must present him before God. Then his master must take him to the door and publicly pierce his ear with an awl. After that, the slave will belong to his master forever."
Ephesians 6:5, "Slaves, obey your earthly masters with deep respect and fear. Serve them sincerely as you would serve Christ."
1 Timothy 2:1-2, "All who are under the yoke of slavery should consider their masters worthy of full respect, so that God’s name and our teaching may not be slandered. Those who have believing masters should not show them disrespect just because they are fellow believers. Instead, they should serve them even better because their masters are dear to them as fellow believers and are devoted to the welfare of their slaves."
“Having been freed from sin, you became slaves of righteousness” (Romans 6:18).
“Act as free men, and do not use your freedom as a covering for evil, but use it as bondslaves of God” (1 Peter 2:16).
While in prison, Paul met a runaway slave, Onesimus, the property of a Christian, presumably Philemon. He sent the slave back to his owner (Philemon 1:10-16).
However, 1 Timothy 1:10 seems to go against most of the Bible and actually condemns “enslavers”.