The US is able to prosecute another country's president.
Ex-Honduran president sentenced to 45 years for trafficking drugs to U.S. https://www.washingtonpost.com/world/2024/06/26/honduras-president-juan-orlando-hernandez-sentenced/
Ex-Honduran president sentenced to 45 years for trafficking drugs to U.S. https://www.washingtonpost.com/world/2024/06/26/honduras-president-juan-orlando-hernandez-sentenced/