The president seemed to soften the criticism Friday by adding, "Everybody makes mistakes."
It was rare public criticism by Trump of his secretary of state.
Trump was speaking to reporters at the White House when he was asked about senior diplomat Bill Taylor.
The diplomat was hired by Pompeo to run the U.S. Embassy in Ukraine after the Trump administration forced out the ambassador in May. Taylor testified Tuesday about an administration effort to withhold military aid to Ukraine in exchange for political dirt on Trump's rivals.
Taylor is a former Army officer and longtime diplomat under Republican and Democratic presidents.