You’re ignoring Paul’s statement that salvation is not by works and he gives the reason, so that no man should boast.
If works played a role in either attaining or maintaining our salvation, then people would have something to boast about in God’s presence and HE would not get all the glory for the work done in our lives. We’d get some for being so good or special, or whatever.
Not if our good works are only by the grace of God through faith.