In my experience, when there is a situation like this, in which a low level student thinks they have found a fatal flaw in the analysis of a peer-reviewed technical paper, 95+% of the time the student has just made a mistake in their own analysis. If the student instantly believes the author of the paper is lying, without making inquiries about the substance of the analysis, I would bump that probability up to 98+%. If the student makes a clear spelling/grammatical error in their description of the issue, bump that probability up a bit more.
Now, perhaps you're one of the small number of cases where the student is correct and the paper is actually fatally flawed. Perhaps this case is even in the extraordinarily rare class of cases where there is a deliberate misrepresentation in the paper by the author, as opposed to an unintentional error. I'm going to play the odds and suggest that you should proceed with caution, making absolutely sure you are correct before you make any contact with the author or the journal. Start from a position where you do not assume malice, and show your work to an academic at your school to see if they understand the analysis any differently to you. If you find that some other skilled person agrees with you then you can write to the author (politely) to inquire into the difference between your own results and the material in the paper.
It is possible to get to a point where it is reasonable to infer an erroneous result in the paper due to deliberate malice by the author. However, that is something that should happen at the end of a long line of sober inquiry and consideration of all possibilities.