Peruvian President Pedro Castillo said on Friday that he has accepted the resignation of Prime Minister Anibal Torres.