You’re already doing undergraduate research and you might be publishing work. You have a good thing going here. Why leave? This research could seriously launch a good career. I would stay if I were you.
Also, your PI got the grant because he has educational credentials. In academics, credentials are everything. That makes it rightfully his grant because it’s his project. If you take credit for the project, the university not only won’t believe you, they will consider it a form of plagiarism, because research projects rely on a chain of command based on credentials. You’ll never be considered for undergraduate research.
On the other hand, if you stick with the project, you might be able to co-author a published paper, and the work you put in would genuinely be yours.
I think the advice here is sound. You’re not doing yourself any favors transferring out, and you’d be literally throwing away a solid opportunity right in front of your nose. This kind of research lands people good jobs out of college.