I am just wondering if BB height from the ground is the same for all bikes or for all mountain bikes, all road bikes, etc? Or does every brand have its own design for that dimension?
No, it is not. Different bikes in the same class (mountain, cross, road, etc.) may even have different bottom bracket heights even among comparably sized bikes. It is a per manufacturer design decision where to place the bottom bracket.
Mountain bikes need higher bottom brackets to clear obstacles vs road bikes or cross bikes, for example.
Most fixed gear frames and track frames have higher bottom brackets to mitigate the possibility of pedal strike on the down stroke since you cannot avoid having your turning-side foot at the six o'clock position while making a turn. Some frame manufacturers make a point to design their frames with a higher bottom bracket for this particular reason. In addition to what others have answered, mountain bikes have higher bottom brackets too (as per the frame manufacturers/engineers' discretion) to clear obstacles.
I would think that the height of the bottom bracket is completely up to the frame designer. However, there must be practical constraints: most cranks are about the same length for adults, 172.5 mm for road bikes or 175 mm for mountain bikes, although other sizes are available (130 mm–220 mm according to this source).
The higher the bottom bracket the taller the bike, other things being equal, so I'd think that raising the bottom bracket reduces the stability of the bike and increases the aerodynamic drag. As @Batman says, mountain bikes need higher clearance than road bikes to avoid obstacles. If the bottom bracket is too low, then riders risk striking the pedals if they pedal through a moderate turn. Because designers nearly universally want to maximize stability, minimize drag, and avoid pedal strikes through moderate turns, and because the vast majority of cranks are nearly the same length, I'd think that the heights of bottom brackets of popular bikes for average-sized adults are all fairly similar, for the same class of bike (road, mountain, etc.). (Of course I'd think that many bikes for children and small people that come with smaller-than-average cranks would have lower-than-average bottom brackets, and that many bikes designed for tall people would have higher-than-average bottom brackets.)