In your human reasoning, you are misinterpreting what Peter said. Here's the Amplified Bible to help you:
1 Peter 3:18-22 Amplified Bible (AMP)
18 For indeed Christ died for sins once for all, the Just
and Righteous for the unjust
and unrighteous [the Innocent for the guilty] so that He might bring us to God, having been put to death in the flesh, but made alive in the Spirit;
19 in which He also went and preached to the spirits
now in prison,
20 who once were disobedient, when the
great patience of God was waiting in the days of Noah, during the building of the ark, in which a few, that is, eight persons [Noah’s family], were brought safely through the water.
21 Corresponding to that [rescue through the flood],
baptism [which is an expression of a believer’s new life in Christ] now [a]saves you, not by removing dirt from the body, but by an appeal to God for a good (clear) conscience, [demonstrating what you believe to be yours] through the resurrection of Jesus Christ,
22 who has gone into heaven and is at the right hand of God [that is, the place of honor and authority], with [all] angels and authorities and powers made subservient to Him.
Footnotes:
- 1 Peter 3:21 Baptism is a public representation of that which actually saves the believer—one’s personal faith in the death, burial and resurrection of Jesus the Messiah.
When a believer is water baptized in the Name of the Father, the Son and the Holy Spirit, the Water Baptism is a SIGN (outward public expression) of the New Covenant of Jesus' Blood and Body - that the believer by personal faith in the death, burial and resurrection of Jesus Christ as Messiah - their Savior - saves them and faith in the power of the Holy Spirit to raise them from the dead - the same Spirit that raised Jesus Christ from the dead.