Use of the word 'an' before words that don't begin with a vowel
Solution 1:
No. The rule is not 'an' before words beginning with a vowel.
It's about the sound, not the letter. The rule is to use the one that's easier to say.
S is pronounces ess. So it's easier to say an than a.
We say a uniform for the same reason: It's easier than saying an uniform.
(By the way, lots of British editors and linguists cringe (or attack) whenever someone suggest that rules exist at all. There are traditions, tendencies, habits, and even conventions, but the English language is ultimately (they insist) whatever we make of it.
To see what I mean, find copies of the American Chicago Manual of Style and the British Cambridge Grammar of the English Language and compare them. One is rules, the other is descriptions.)