In the UK this is governed by the Equality Act 2010, which prohibits discrimination against disabled persons. Official guidance as to what counts as "disability" can be found here, but the basic definition in the law (as paraphrased here) is "substantial" and "long term" difficulty in carrying out every-day tasks.
‘substantial’ is more than minor or trivial, eg it takes much longer than it usually would to complete a daily task like getting dressed
‘long-term’ means 12 months or more, eg a breathing condition that develops as a result of a lung infection.
Allergies are long-term, so the question is whether a food allergy presents substantial difficulty in carrying out every-day tasks.
The kind of every-day tasks that the guidance considers are things like getting dressed, preparing a meal, meeting work deadlines, typing or writing.
The guidance does not specifically mention allergies. However the mere existence of an allergy would not create substantial difficulty in carrying out this kind of every-day task. So it would not be considered a disability.