There are two possibilities to use demonstrative pronouns. One is that an element of group is referred to, but this element or the group is not clearly defined:
Example
Celui qui le sait, est heureux.
The one, who knows it, is happy.
Ceux
qui ne savent pas écrire, ont
du mal à se débrouiller
dans la vie.
The ones, who do not know to write, have problems to get along in life.
The other possibilities is that the demonstrative pronoun refers to something that is visible.
Example
Celui qui traverse la rue, est mon oncle.
That one, who crosses the street, is my uncle.
Celle qui traverse la rue, est ma tante.
That one, who crosses the street, is my aunt.
Actually it is used the same way as in English. Best way to handle demonstrative pronouns is not to think about it too much and use them just according to your own gut's feeling.