That is NOT true. Here is how the Electoral College system works in the USA. This is the explanation taken from the USA Election information website
https://www.usa.gov/election#item-36072
After you cast your ballot for president, your vote goes to a statewide tally. In 48 states and Washington, D.C., the winner gets all the electoral votes for that state. Maine and Nebraska assign their electors using a proportional system.
A candidate needs the vote of at least 270 electors—more than half of all electors—to win the presidential election.
In most cases, a projected winner is announced on election night in November after you vote. But the actual Electoral College vote takes place in mid-December when the electors meet in their states.
While the Constitution doesn’t require electors to follow their state's popular vote, many states' laws do. Though it's rare, electors have challenged those laws and voted for someone else. But in July 2020 the Supreme Court ruled (PDF, Download Adobe Reader)that those state laws are constitutional. Electors must follow their state's popular vote, if the state has passed such a law.
So in fact, the president of the United States IS indeed elected by the people because the electors in the electoral college for each state are required to vote according to how the people voted in that state whether the winner is determined by a "winner take all" approach or a proportionate approach.
For the House of Representatives and the judiciary system, it's still better that they are elected vs. in China and in many countries even including Canada, another branch of the government like the Senate and the judges are appointed by the sitting leader of the country.
So it's really inappropriate to compare the forming of the US government branches and the election of its leader to the absolute dictatorial nature of how a leader is chosen in countries like China where the people do not have any choice of even which candidate(s) can land on a ballot. Check for how Hong Kong, a region that's supposed to be allowed to follow its own democratic process of leader selection can elect its own leader.
No system is perfect and the electoral college is no means free of flaws but it is still a far cry from being undemocratic. If countries like and including China can get something even just remotely resembling the US election process, its people will be lot more happier.