the secret ballot was introduced in the 1920’s so the voter can vote anonymously. it was to prevent the voter from getting stereotyped, hated on, threatened, etc. by others who were against who the voter voted for. it was also not wanting their name out there for others to know who they voted for,
just for a sense of the voter wanting their own privacy/space in general.