Bees can rival mammals in problem-solving intelligence. They can also want things, which gives them a rudimentary form of consciousness:
Honeybee scientist Andrew Barron and philosopher Colin Klein, both then at Macquarie University in Australia, argue that bees have some form of consciousness. Let’s look at what they have to say:

According to an article in Smithsonian Magazine, Barron broached the question of bee consciousness with Klein, who was highly skeptical at first. But Barron pointed out that at least one key theory holds that
…the core of human consciousness is not our impressive neocortex, but our much more primitive midbrain. This simple structure synthesizes sensory data into a unified, egocentric point of view that lets us navigate our world. Insects, Barron and Klein now argue, have midbrain-like structures, including a “central complex,” that seem to allow bugs to similarly model themselves as they move through space.
ABIGAIL TUCKER, “DO INSECTS HAVE CONSCIOUSNESS?” AT SMITHSONIAN MAGAZINE (JULY 2016)
The dialogue resulted in an open-access paper in the Proceedings of the National Academy of Sciences (PNAS).
It is important to qualify what “consciousness” means when we are talking about bees: …
News, “Can insects be conscious? Let’s look at bees first” at Mind Matters News (February 3, 2022)
Takehome: Consciousness does not seem to reside in the neocortex. So complex behavior in bees has raised the question for biologists and philosophers alike.
You may also wish to read: How do insects use their very small brains to think clearly? How do they engage in complex behavior with only 100,000 to a million neurons? Researchers are finding that insects have a number of strategies for making the most of comparatively few neurons to enable complex behavior.