In Genesis 14:18 it is stated that "And MelchiZedek, king of Shelem, brought out bread and wine and he was a Kohen to the Most High God." A number of questions arise from this: How is it possible for non-Jews to have the status of a Kohen? And another question, how could Abraham, who was a Kohen according to some interpretations because he was about to sacrifice Isaac in the Akeidah and accepted the commandments of the Torah, accept from another Kohen bread and wine that are not allowed to be accepted by Torah? And if Abraham is considered a Kohen, how does a Kohen receive a gift from other Kohen? And why Abraham not say to Malchizedek that only one who is descended from Abraham (Jewish) and no other is considered a Kohen?
How is it possible for non-Jews to have the status of a Kohen?
So firstly, Shem the son of Noach is identified as Malkitzedek (Bereishis Rabbah 56:10) - whilst we attribute Avraham as the "first Jew", Shem was regarded as a tzaddik - he was born circumcised (See Bereishis Rabbah 43:6 and Avos DeRabbi Nosson 2:5), he prophesied for 400 years to the idol worshipper but they didn't listen to him (Tanna D'Vei Eliyahu Rabbah 24 - "שם הגדול בן נח שנתנבא ארבע מאות שנה על כל אומות העולם ולא קבלו ממנו") even Avraham admitted openly that when the nations of the world sought to turn away from G-d, Hashem selected two prominent members (Shem & Eiver) of my father's family to rebuke them (Bereishis Rabbah 52:11), and he was already engaging in Torah (refer to quote from Zohar Chadash, mentioned later).
How could Abraham, who was a Kohen according to some interpretations because he was about to sacrifice Isaac in the Akeidah and accepted the commandments of the Torah, accept from another Kohen bread and wine that are not allowed to be accepted by Torah?
According to the Midrash this is not to be understood literally as food.
Bereishis Rabbah 43:6 explains it in a more symbolic way...
(בראשית יד, יח): הוֹצִיא לֶחֶם וָיָיִן וְהוּא כֹהֵן לְאֵל עֶלְיוֹן, רַבִּי שְׁמוּאֵל בַּר נַחְמָן וְרַבָּנָן, רַבִּי שְׁמוּאֵל אָמַר הִלְכוֹת כְּהֻנָּה גְדוֹלָה גִּלָּה לוֹ, לֶחֶם, זֶה לֶחֶם הַפָּנִים. וָיָיִן, אֵלּוּ הַנְּסָכִים. וְרַבָּנָן אָמְרֵי תּוֹרָה גִּלָּה לוֹ, שֶׁנֶּאֱמַר (משלי ט, ה):
[He] took out bread and wine, and he was a priest of God, the Most High” – Rabbi Shmuel bar Nacḥman and the Rabbis, Rabbi Shmuel said: He revealed to him the laws of the High Priesthood. “Bread” – this alludes to the showbread; “and wine” – this alludes to the libations. The Rabbis say: He revealed Torah [precepts] to him, as it is stated: “Come, partake of my bread, and drink of the wine that I have mixed” (Proverbs 9:5).
And why Abraham not say to Malchizedek that only one who is descended from Abraham (Jewish) and no other is considered a Kohen?
This is because as per the Gemara in Nedarim 32b Hashem initially sought to bring the priesthood from Shem/Malkitezedek...
Rabbi Zekharya said in the name of Rabbi Yishmael: The Holy One, Blessed be He, wanted the priesthood to emerge from Shem, so that his children would be priests, as it is stated: “And Melchizedek king of Salem brought forth bread and wine; and he was priest of G-d the Most High” (Genesis 14:18). Once Melchizedek, traditionally identified as Shem, placed the blessing of Abraham before the blessing of the Omnipresent, He had the priesthood emerge from Abraham in particular, and not from any other descendant of Shem. As it is stated: “And he blessed him and said: Blessed be Abram of God Most High, Maker of heaven and earth, and blessed be G-d the Most High” (Genesis 14:19–20). Abraham said to him: And does one place the blessing of the servant before the blessing of his master? You should have blessed God first. Immediately the Holy One, Blessed be He, gave the priesthood to Abraham, as it is stated: “The Lord says to my lord: Sit at My right hand, until I make your enemies your footstool” (Psalms 110:1), and afterward it is written: “The Lord has sworn, and will not repent: you shall be a priest forever, because you are a king of righteousness [al divrati malki tzedek]” (Psalms 110:4), which is explained homiletically to mean: Due to the improper words [divrati] of Melchizedek, the offspring of Abraham shall be priests of God forever. The Gemara comments: And this is as it is written: “And he was priest of G-d the Most High” (Genesis 14:18), which emphasizes that he, Melchizedek, is a priest, but his children will not be priests. (William Davidson translation & notation).
Indeed, refer to the Zohar Chadash on Noach which writes pretty emphatically:
אָמַר רִבִּי יוֹחָנָן, וַהֲלֹא יֶפֶת הוּא הַגָּדוֹל, לָמָּה שֵׁם נָטַל הַכְּהוּנָּה. בִּשְׁבִיל שֶׁהָיָה תָּמִיד עוֹסֵק בַּתּוֹרָה, וּפֵירַשׁ מִדַּרְכֵי הָעוֹלָם. וּמֵאַיִן הָיָה לוֹ תּוֹרָה. אֶלָּא אָדָם הָרִאשׁוֹן יָדַע הַתּוֹרָה, וְהִנִּיחָהּ בְּקַבָּלָה לְשֵׁת בְּנוֹ, וְאַחַר כַּךְ בָּאָה לְיַד חֲנוֹךְ, עַד שֶׁבָּא לְשֵׁם וְהָיָה מִתְעַסֵק תָּמִיד בָּהּ
Rabbi Yochanan said: Wasn't Yefes the oldest one (i.e. the oldest son), why then was Shem given the priesthood? Because he was always engaged in Torah and interpreted the ways of the world. And from where was his Torah? Adam HaRishon knew Torah and he passed it one Sheis his son, and after that it came to Chanoch until it came to Shem who was always engaged in it.
Refer to Tehillim 110:4. The meforshim there explain that "priesthood" could also mean leadership.
For example, Rashi (sv. דברתי מלכי צדק) says:
The word כהן bears the connotation of priesthood and rulership, as (II Sam. 8:18): “and David’s sons were chief officers.”
Similary, look at what the Malbim says:
נשבע, עד שמה שנשבע ה' לתת לך את המלוכה לא ינחם ע"ז ע"י החטא, ומפרש מה היה השבועה, ה' נשבע שאתה כהן לעולם על דברתי אתה מלכי צדק! קורא את דוד בשם מלכי צדק, ע"ש המלך הראשון שהיה בירושלים, כמ"ש ומלכי צדק מלך שלם, (כי כן היה שם מלכי ירושלים מקדם), והוא היה כהן לאל עליון, ועל מליצה זאת אמר שאתה תהיה כהן לעולם, ואחר שתפס שם כהן אמר על דברתי שתהיה כהן על הדבור שלי דהיינו על המקדש והדביר, גם הזכירו בשם מלכי צדק לאמר כי צדיק הוא בעיניו ונשאר בצדקתו כי מחל חטאו
It is about Dovid HaMelech.
“You are a priest (guardian of the Temple), and you are a continuation of the first king of Jerusalem, Malki Tzedek. You, like him, are righteous.
The Metzudos says that it refers to a servant of G-d.
So maybe the term Kohen, in this case, connotes being a King, a leader.