Jordan Cooper has an excellent discussion of what the Bible says about slavery. You need to read it all, but I’ll quote six points that he makes.
I then want to propose a way to apply these passages–not just to their historical context–but to the slavery of sin.
From Jordan Cooper, Does the Bible Support Slavery?, Just and Sinner:
This, I think, is a good account of the cultural and economic meaning of slavery in the ancient world. But if all Scripture is written for our instruction (Romans 15:4), what do we do with the slavery passages in a culture and an economy without slavery?
Now there is much in the Bible that seems shocking. Those who see the Bible as primarily a textbook for morality have to bend some passages to make what it says seem better than it appears. But the purpose of the Bible is not primarily a guidebook for life. Its main purpose is to drive us to Christ, or, rather, by bringing Christ to us. This it does by devastating us with God’s Law (some of the shocking passages do this by showing us just how alien and all-consuming and frightening God’s righteousness is) and then bringing us back to life and joy by communicating and conveying the Gospel of Christ’s redeeming and forgiving work on our behalf.
So how do the slavery passages, whatever their historical and cultural context, contribute to that overarching purpose? Well, there is slavery mentioned in the Bible that still exists: the slavery of sin (John 8, Romans 6).
This does NOT mean that slaves are sinners, as in blaming the victim; it means that sinners are slaves. The one we obey is our master, as both Jesus and St. Paul explain in the above texts, and our sinful nature is such that we are not free to just be good if we want to; rather, in Luther’s terms, our very wills are in bondage, so that we are slaves to our fallen flesh, to our twisted impulses, and to Satan himself. We sinners are ALL slaves, so that the slavery passages apply to us.
So the passages about historical slavery and how it was governed under the Levitical law, while mitigating the institution as it was practiced by the Canaanites and later the Romans, speak to us of our condition under sin. To apply Rev. Cooper’s points, they teach us that sinners are still human beings; that someone who leads someone else into a particular slavery to sin (a seducer, a corrupter, etc.) is guilty of a sin that deserves death and damnation, etc.
It follows that the freeing of slaves in the Bible is an image of redemption. The deliverance of the Israelites from their slavery in Egypt is described in these terms (Hebrews 11:29). Jesus and St. Paul also talk that way when the latter speaks about the freedom of the Gospel (Romans 6) and when Christ says that “if the Son sets you free, you will be free indeed” (John 8:36).