Storage of partially used jar of mustard?
Mustard often separates, it doesn't mean it's going bad. It's likely perfectly fine, mustard stays good for years in the refrigerator. Just stir it up before using it to recombine. 

As for why it doesn't separate unopened, sometimes it does. Often you are buying a product that's been manufactured recently, so it hasn't had time to separate yet.