Thus, towards the start of Pinchas, we read:
|13. It shall be for him and for his descendants after him [as] an eternal covenant of kehunah, because he was zealous for his God and atoned for the children of Israel."||יג. וְהָיְתָה לּוֹ וּלְזַרְעוֹ אַחֲרָיו בְּרִית כְּהֻנַּת עוֹלָם תַּחַת אֲשֶׁר קִנֵּא לֵאלֹהָיו וַיְכַפֵּר עַל בְּנֵי יִשְׂרָאֵל:|
|והיתה לו: בריתי זאת:|
|an eternal covenant of kehunah: For although priesthood had already been given to the descendants of Aharon, it was only given to Aharon and his sons, who were anointed with him, and to their descendants who were born after their anointing. But Pinchas who was born before this and was not anointed, he did not come into the category of kehunah until now. And so do we learn in Zevachim 101b, Pinchas did not become a kohen until he killed Zimri.||ברית כהנת עולם: שאע"פ שכבר נתנה כהונה לזרעו של אהרן, לא נתנה אלא לאהרן ולבניו, שנמשחו עמו ולתולדותיהם שיולידו אחר המשחתן, אבל פינחס שנולד קודם לכן ולא נמשח, לא בא לכלל כהונה עד כאן. וכן שנינו בזבחים (קא ב) לא נתכהן פינחס עד שהרגו לזמרי:|
That gemara in Zevachim reads:
דאר"א א"ר חנינא לא נתכהן פינחס עד שהרגו לזמרי דכתיב (במדבר כה, יג) והיתה לו ולזרעו אחריו ברית כהונת עולם רב אשי אמר עד ששם שלום בין השבטים שנאמר (יהושע כב, ל) וישמע פינחס הכהן ונשיאי העדה וראשי אלפי ישראל
However, if we read that gemara in Zevachim carefully, we see that it is actually a machlokes whether Pinchas only became a kohen then. See the Point by Point Outline: For there is
Thus, at the least, there is Rav Ashi arguing with R' Eleazar. But further, there is an opinion that Pinchas was already a kohen, such that the gemara's question that Pinchas was with them, והלא פינחס היה עמהן, such that he could have eaten it, makes sense. Thus, there is certainly a dispute in place in midrash as to how to understand these pesukim.
Therefore, it would be no surprise if the Zohar presents an interpretation which differs from the one proffered by Rashi. Even without getting into early or late authorship, we can simply say that this reflects a competing midrashic understanding.
The Zohar on Pinchas reads:
At least according to the English translation here, it seems as if Pinchas was initially a kohen and lost that status, requiring reinstatement as a kohen. I am not so sure that we need to translate it like this. Nothing in the Aramaic original requires this interpretation. Thus, מן דינא פסיל לכהנא הוה does not mean that he was legally barred from remaining a priest. It could mean that he was legally barred from becoming a priest. So so, ליחסא ליה כהונת עלמין does not require a translation of reinstating. We might be able to give a far-fetched haemonization.
Still, there is a reason they translated it as such. We are primed for such an interpretation from the law about someone who is already a priest who disqualifies himself.
But if the Zohar has him already a priest, does this not contradict Rashi? Why doesn't Rashi cite the Zohar? And why doesn't the gemara give this explanation?
I don't see these as questions. First, Rashi was not cognizant of the Zohar. Whether this is because it was not authored yet, or because he was not one of the yechidei segulah. As proof of this, consider the following Rashi on Kiddushin 71a:
שם - בן שתים עשרה ובן ארבעים ושתים לא פירשו לנו:
"The name of 12 letters and of 42 letters they have not explained to us."
Meanwhile, citing from elsewhere:
So how could Rashi not know the specifics of the 42 letter name, and claim that לא פירשו לנו? It must be that he was not one of the yechidei segulah who passed down the Zohar.
So much for Rashi. What about the gemara? Well, we will just revert to the assertion that this was a matter of midrashic dispute.