To jump into Romans 6, and the question asked in verse 1, without first knowing the theology that Paul outlined in chapter 5 could, potentially, lead to missing a major point of God's Word.
In chapter 5 Paul makes clear that only Jesus Christ can save the ungodly from the Wrath of God - Christ died for the unrighteous and by His Blood many were made righteous and given the free gift of eternal life by God's Grace. Where sin abounds, Grace abounds MUCH MORE! Those IN CHRIST are no longer under Law, but are now under GRACE!
The rhetorical question posed by Paul in Romans 6:1 in paraphrase is, "if I'm under Grace, not Law, it's no big deal if I sin, right?"
If a person is asking this question from the vantage point of wanting license to sin it shows their enslavement; after all, we are all slaves, the question is, what are we enslaved to?
We are either slaves to sin or righteousness.
Sin leads to death. Obedience leads to righteousness.
Romans 6:17 shows that there is a "teaching" that takes place. Let's consider what "teaching" is. Teaching informs and ultimately changes our mind. It either reinforces what we already know, or it challenges what we thought was right. Therefore, it is through "the standard of teaching we are committed" that leads to obedience from the heart, and it is obedience to God's Word that leads to righteousness. We are "legally" made righteous by the imputed righteousness of Christ; but it is through obedience to God's Word, and the power of the Holy Spirit, that we live right.
As we give ourselves to righteousness, and are slaves to righteousness, we are being sanctified, we are growing in the likeness of Christ. Being a slave to God ultimately leads to Eternal Life.
Romans 6:1-2 What shall we say then? Are we to continue in sin that grace may abound? 2 By no means! How can we who died to sin still live in it?
Romans 6:17-23 But thanks be to God, that you who were once slaves of sin have become obedient from the heart to the standard of teaching to which you were committed, 18 and, having been set free from sin, have become slaves of righteousness. 19 I am speaking in human terms, because of your natural limitations. For just as you once presented your members as slaves to impurity and to lawlessness leading to more lawlessness, so now present your members as slaves to righteousness leading to sanctification. 20 For when you were slaves of sin, you were free in regard to righteousness. 21 But what fruit were you getting at that time from the things of which you are now ashamed? For the end of those things is death. 22 But now that you have been set free from sin and have become slaves of God, the fruit you get leads to sanctification and its end, eternal life. 23 For the wages of sin is death, but the free gift of God is eternal life in Christ Jesus our Lord.