For the sake of etiquette, let's try to take the friends-with-benefits thing out of the equation for a moment.
Let's re-write this situation with three men. Let's assume there are three men, all three of them 100% hetero, just to take all romantic and sexual clouding out of it.
John would STILL be wrong.
If one friend offers to treat you to dinner, you do NOT drag someone else along. You just don't do that. The friend has offered to treat YOU. They have invited you. Not someone else.
Either you're comfortable going to dinner with them alone, if they invite you alone, or you're not. If you don't want to, you politely decline. You don't change the rules of their invitation.
Let's take a different situation now, the other extreme: let's say that John and Emma are a married couple. A third party, whether male or female, invites John to dinner to treat him as a thank-you for helping them out or whatever.
John would STILL be wrong to invite his wife along. Again, if he's not comfy going out with the inviter alone, or if it's "not done" in his marriage to go out without his wife and with another woman... he can politely decline. But you do not, when invited to be treated, take the initiative to take someone else along: not your wife, not your friend, not your mother, not your child, not your friend-with-benefits.
So no matter what, John was rude to Carol for inviting someone else along when she had invited him to a dinner - her treat.
John was also rude to Emma. Regardless of their relationship. It's always awkward to feel "unwanted" by the "host" or "inviter" if you realise they didn't want to invite you and someone else has invited you while it wasn't their place to do so. It is not cool to put your friend, wife, lover, coworker, dog, child, in short anyone in that position.
It is possible that John likes Emma more than some posters think, and that he didn't want to go out with Carol, and indeed used Emma as a "buffer". But while doing so, he trampled all over etiquette AND made it awkward for Emma.
If he wanted to use Emma as a buffer and make it clear to Carol that "this was not a date", he should probably have done better trying to include Emma in the conversation much more.
It is also possible that John is "not that into" Emma and even that *Emma* is okay with that. I didn't get from the OP that "Emma saw her world falling to pieces at the sight of John flirting with someone else", or anything. Just that Emma found it awkward that it was done in front of her. Maybe Emma wouldn't have minded if John had honestly and openly said: "Hey, I'm going out for dinner with Carol today, don't wait up for me".
But what is a red flag in the OP for me is that it is worded as "They don't have a label YET". That sort of hints to me that Emma is hoping for the future and that in her mind, they are more than in John's mind. And she has to be careful with that, and realistic.