President is elected by the Congress, which is a different position from the General Secretary which elected by the Central Committee. Sometimes these positions are shared by the same people, and sometimes they aren’t.
The Communist Party is based in the Leninist principle of “democratic centralism”. This means “debate within the party, unity in action”. It is meant to make the party more powerful by allowing dissent and debates within the party, but when it comes to taking action, all members are expected to follow the consensus even if they disagreed with it.
Since China’s Congress is primarily members of the Communist Party, this means that the decision of the president ultimately originates in the Communist Party itself. After they reach a consensus, the whole party will vote for that consensus in the Congress. While there technically are smaller parties in China’s Congress, they act more as advisors, since it is not practically possible for them to overturn the vote, since the CPC always votes in unity.
Formally, China’s president is elected by the Congress. But the decision of who to elect largely comes back to the CPC itself before they come to a consensus. So the final decision largely originates in the Politburo and the Central Committee.
The president in China is harder to shift on a dime than like in the US. The president is not elected by a nation-wide vote but by the Congress itself. To change who the Congress elects, you have to change the opinions of the largest party in that Congress, you have to change the opinions of the CPC.
To change the opinions of the CPC, you will need to change the make up of the Central Committee and the Politburo. To change their make up, you have to change the make up of the people below them. And to change the make up of the people below them, you have to change the make up of the people below them. So on and so forth.
It all comes back down to the very local and grassroots level. As an individual, you only have voting power to change the grassroots make up of your local area. You can nominate and vote in someone different at the base, but you can’t vote directly on the president.
This means for the president to change, there needs to be an overall shift in public opinion in the majority of the entire country, which would change the make up of the majority of the people at the bottom, which would then change the make up of the majority of people above those people, which would then change the make up of the majority of people above those people, so on and so forth, until it changes the Politburo and Central Committee.
At that point, the positions of the CPC would be changed and you could get a different president elected. Of course, that would take a long time. So changing the president is not something that can happen quickly.
China’s system really thrives off of stability, centrality, and consensus. It is meant to both democratically take into account general public opinion, but also to centralize those opinions into a particular decision and consensus. The entire political system is structured to encourage a greater and stronger consensus to form the more you “move up” the electoral system.
By the time you get to the Congress electing the president, the consensus is already largely formed. The Congress more-so acts as a way to formalize that consensus, but to also give some input from outsiders, such as the CPPCC acts as an advisory body to the Congress and has many representatives who are not members of the CPC. Advisory bodies still play an important role even if they don’t directly get to decide things.
Elections are anonymous so there are still sometimes people who vote against it, but this is mostly for symbolic reasons, since by the time the vote comes in front of Congress, the decision has largely already been made in the CPC, and this is just the way it is formalized.