It seems fairly clear to me that if someone goes to a designated US port of entry and requests admission for purposes of gaining asylum they are NOT attempting to enter the United States illegally. Below is a quote from an Arizona law firm that specializes on immigration law.
My understanding is, if an asylum seeker goes to a port of entry and requests admission in order to request asylum they are not attempting to enter illegally. How could they be when they have the right under international and US law to seek asylum?
Your quote states to avoid prosecution for illegal entry not that the entry is actually legal.
edit - apologies you actually referenced port of entry. Yes, that is correct. If you approach a designated port of entry and hand yourself in, that is not illegal entry.