Non-native speaker here. To me in spoken language both "unicorn" and "hour" have a combination of 2 vowels in the beginning. Let me transcribe them as "ee-oo" and "aa-oo" here.
Why is the aa-oo combination at the beginning of "hour" considered a vowel but the ee-oo in "uniform" is a consonant?
I didn't get the unicorn thing either, but it's explained better in the longer post (https://www.redblobgames.com/x/2635-a-vs-an/). Unicorn is pronounced starting with a sound like 'you', which starts with a consonant.
To me, the ee-oo sound feels more like a Y in my mouth. However if I really draw out the word slowly it feels like ee-oo. But in practice it feels like Y.
I would transcribe the first sound of “unicorn” as “yoo“. It’s almost ee oo but the ee isn’t voiced—it starts right at the transition between those which is what the Y sound is.