S.G.
It isn't unusal for children that age to have fears of different, unknown things. My 1 year old granddaughter loves watching tractors and trucks working on the road in front of the house (we have a huge road rebuilding project going on out front) but she screams if we try to get her to sit on the backhoe or bobcat with her grandpa, even though they are enclosed cabs. My oldest son was afraid of any loud sounds and had a horrible fear of heights. He outgrew it though.
My guess is when your son can start opening the doors himself (around 18 mo to 2 years) he will see he can control being shut in and he will feel more comfortable. Elevators are pretty scary for some, you go in this room, when the door opens, you are somewhere else but you didn't walk anywhere. Some love this. My granddaughter was 11 months old when my mother was in the hospital on the 10th floor and she would have me "walk" her around, leading the way back to the elevator each time. She surprised me that she knew right where the elevators were and insisted on going up and down them over and over. She would giggle each time the elevator would move cuz it tickled her tummy. So be patient, chances are he will change his likes and his fears many times over his childhood.