I sympathise OP,
My DS (9) has a longstanding friend (12) who is an utter nightmare. I used to avoid having him around whenever possible but when he came over as part of the group of old friends' kids he always refused to eat, despite demanding I cook something different for him.
He basically challenged anything we ask him to do (or stop doing!). It's incredibly wearing and makes the whole thing exhausting and stressful.
Things got worse and worse. He really was spoiling things for everyone else until I finally (when he was 6) put my foot down and explained to him that, if he wanted to come here for a sleepover/tea etc, he had to follow our house rules. (eating something from the selection offered, not demanding I cook or order something special for him then pushing it round his plate; dinner at the table not while playing the Wii; upstairs to wash and change when we call bedtime; not teasing the dog etc).
Just stuff that makes having a group of bigger kids round at mine easier when I have a job, younger DCs and baby to deal with too!
Shortly afterwards his mother confided in me that he'd never been invited round anyone else's house a second time but had recently started to be asked a little more often .
From your post it sounds like your DC's friend, although much younger, was difficult in a similar fashion and the eating thing was just symptomatic of not knowing how to behave at other people's houses.
I think you would be doing this child a favour if you gently explained some of the etiquette of visiting for tea. I wouldn't get into a battle about it, but kids often accept different rules for different places quite easily.
You may also find it easier to do a selection of sandwiches with stuff like sliced cucumber, cherry tomatoes, cheese cubes, bread sticks etc so everyon can pick and choose what they like at this age. Easier on you and less likely to result in a refusal to eat standoff.
Also, get a heads up from parents beforehand what their kids like eating.
Also, you can use a visitor's bad behaviour to show your kids what they shouldn't be doing (after visitor has gone). Ds and I used to have quite a laugh about how irritating his friends antics were (I do a great impression!).
My DC's difficult friend still tries it on but now accepts me laying down the law.
DH still point blank refuses to have him over if I'm out tho . And having him here with his parents is another story altogether. I love them to pieces but hate having to tell him off while they studiously ignore his behaviour or watch him having a major tantrum at them to get what he wants .
I think you are within your rights to insist on some rules that make having kids round fun for all .
YANBcompletelyU