Ooh... Interesting problem. I'm going to focus on a potential evolution path rather than just saying 'it's unlikely' because it's more fun!
The biggest issues are where to put the organs and how to make it float. If we look at traditional images of
beholders floating eye creatures we can see that they're depicted as having a mouth, so we can assume they eat and don't photosynthesize etc. The sharp teeth also suggests carnivore, which helps with the energy requirements somewhat. The space given over to the mouth also gives an opportunity for a compact in-situ digestive system, somewhat similar to a snake crossed with a pelican. Once prey is incapacitated (which I'll get to) the beholder floating eye creature reticulates its jaw, expands its 'digestive pouch' (gullet merged into stomach), swallows the prey like a snake and sits, grounded, while it digests it. When it's done it spits out the bones and flies off. Our beholder floating eye creature has a vestigial anus, just as a point of interest.
Obviously the above suggests an evolutionary track from a snake, or an ancestor of snakes, so we're likely looking at a cold blooded creature. From here we get a possible evolutionary track for flight, as creatures that can rise above low lying fog etc would be able to stay active longer than ones that can't, matching up neatly with the hunting patterns of the
beholder floating eye creature (why hunt prey when you can eat it as it sleeps?). There are a number of gases that could help with the floating, some of which may be byproducts from the digestive fluids used. This creature is grounded while eating, and eats to avoid being grounded. How paradoxical.
The other organs can be distributed neatly around the flesh of the creature. There's a lot of surface area to fill with (very flattened but still functional) organs, and if you're happy moving some functions out into the tentacles (a-la octopus) then things like liver/kidneys etc can be shifted fairly easily. The brain is a little trickier, as it needs to be fairly localized, but this gives us a wonderful reason for why they have such big eyes in the first place.
Flies (and many insects) do a lot of processing in specialized neural clusters fastened directly to the eyes. This has a lot of advantages for them, as it lets them react faster as the distance from input-reflex is much shorter. Now imagine a lizard living in low lying fog. It might have only a millisecond before it can see a predator dropping down from above, so it needs to be able to see, think and react very quickly to survive. As such: It develops specialized processing that links to it's defensive system (again, I'll get to it in a second) and is situated directly behind the eyeball (I can't explain the mono-eye, we've got to go very far back in the evolutionary chain for that). Over time this eye-brain develops, and the creatures head adapts commensurately. The musculature for ocular motion is a tricky one, but it's possible if you assume the creature hasn't got a massive amount of 'scan' to the eyeball (it can't track massively far, preferring instead to turn it's head) The larger surface area allows the creature to utilize some of the previously wasted gases for lift, and it starts to use a combination of jumping and tentacles to 'fly'. The body and legs become vestigial, and you have your
beholder floating eye creature. One major concern is the weight of the eye, but it's not inconceivable to have an eye held up by struts instead of fluid (though it is weird. Perhaps a part of the 'single eye' evolution way back in the dawn of time?)
Now the defensive system becomes a hunting system for immobilizing prey. What is the defensive system? A series of tentacles with stings on the end. In the early lizard the eyes were used to rapidly orient the stings towards incoming predators, reducing the amount of energy needing to be expended on growing all-round spiny coverage. In the later lizards where the eye is taking more direct control of signal processing the tentacles become a predation system as well as a tool for manipulation and flight (flight might need some specialized 'paddle like' tentacles)
On the subject of using the eye as a weapon: I can't think of any way to make it directly offensive, but if the eye is photo-luminescent it would act as a lure for any stray creatures lost in the fog, enabling a grounded
beholder floating eye creature to lure, sting and devour a creature to refill its floats. I think that would count as dangerous.
TL:DR : It evolved from a one eyed lizard in a very foggy place. This explains its fondness for crypts, dungeons, and mysterious mists.
Addendum: On the eye structure: A fish-like creature in the dim and distant past was predated upon by smaller fish that would nip at its soft fleshy eyeballs. Over time those eyeballs grew hardened and chitinous, leading to diminished visual acuity but stronger eyes. As these eyes formed they developed internal strutting to hold the eyeballs rigid rather than risking cracking/stress injuries. When this fish's ancestors eventually made it to land their eyes drained of most fluid, leaving them with a hollow (light) eyeball and terrible eyesight. This explains the lizard's weird requirement for faster eye-reaction time (it's almost blind), it's predilection for foggy places (Why live where you've got the shortest vision? Go somewhere everyone is blind!) and (almost as an afterthought) The unique angular patterns some
beholders floating eye creatures seem to have in their eyes.