The article is unnecessary. "I am making onion and carrot soup" is correct and more common.
I think we need an "and". In Britain, for example we have "leek and potato" soup, and I'm about to go off and eat my "carrot and coriander" soup.
Would it also be correct to say 'I am making soup from (using) onion and carrot'?
I would say that "from", "out of", "using" change the case to Genitive, so that would be "z cebuli i marchewki".
I got 'carrot and onion soup' corrected to 'onion and carrot soup', which sounds wrong - certainly because it is more awkward to say; possibly also because carrot is implicitly the main ingredient.
Even if it sounds more natural your way (I guess I could agree), we have to keep the order of those vegetables the same way, to be sure that you don't mix them, that you know which one is which.
I'd say that "marchew" is a mass noun and "marchewka" denotes one carrot... but actually they could be used the other way round as well ;) At least I can imagine my mom saying "Kup marchewkę" and she won't mean one carrot.
Could this construction also be used in a situation where the "primary" ingredient that would define the type of soup is something else, but it also contains onions and carrots? For instance, I make lentil soup with onions and carrots.
Yes. Actually we mostly use adjectives for describing the soup, just like English does: zupa pomidorowa = tomato soup. So here 'with' is indeed just 'with', whether those are main ingredients or not.