An illusion was a pseudo-reality created by natural and/or artificial means. For an individual experiencing the illusion, it could be as real as the thing in reality and just as hard to dismiss. The illusion was based on an individual's thoughts, memories, experiences, and dreams.
Some Telepathic species had the natural capacity at creating an illusion for an individual. This act of creation could have a therapeutic effect on an individual who was physically incapacitated. The danger for the telepath was that they could become lost in the illusion, feeling the emotions of the individual, and, over time, become addicted to the experience. As the telepath lived and relived the illusionary life of the individual, he or she would gradually give up the ability to travel, to build, and to create. The danger for the individual was that he or she may learn how to create illusions and, potentially, travel upon the same path as the telepath. (TNG: "The Cage")