I do not understand why they think confessing to a man gets sin forgiven. Only Jesus can do that so why not go directly to Him?
They think that because they've been raised having been taught that.
As for why hey are taught that, well, it's quite a racket the Catholic church has going there.
Convince people that their sins can only be forgiven through you and viola, job security and complete control of their lives to boot.