The voting system where the choice with the most votes wins is called "first past the post".
Ranked ballot voting systems differ by requiring voters to list most to least favourite choices (1, 2, 3...). There are different ways to employ ranked ballots, but one is the alternative vote. Generally with this method, in the case where a voter's first choice is eliminated by receiving the least number of votes upon the first count, their second choice would count as their vote, so their votes are reallocated to the remaining choices. Here is a video that explains it in detail; the YouTube channel that created it has other videos about different voting systems that may be of interest: https://www.youtube.com/watch?v=3Y3jE3B8HsE
in Indonesia, to elect the senators which has 4 seats in each district (provincial based), voters only vote for 1 candidate, so we don't apply the ranking. eventhough the elected candidates would be determined based on the rank of votes they got.