I am answering your question with taking help of different scriptures like Upanishads ,Puranas and works of Acharyas like Adi Shankaracharya ,who in very detail described this Maya.
Then scriptures are giving us not only the definition of Maya ,but also telling us about it's creator and it's nature as well as ways to liberate from bonds of maya.
Let's see one by one what some of the texts are saying
In the book Vivekachudamani Shree Sankaracharya says that Maya is the power of the Lord. Maya is without beginning, is made up of the three gunas and is superior to the effects as their cause. It is to be inferred by one of clear intellect only from the effects it produces. It is that which brings forth this whole universe. Maya is neither existent nor non-existent nor partaking of both characters; neither same nor different nor both; neither composed of parts nor an indivisible whole nor both. It is most wonderful and cannot be described in words.
अव्यक्तनाम्नि परमेशशक्ति -
रनाद्यविद्या त्रिगुणात्मिका परा ।
कार्य्यानुमेया सुधियैव माया ।
यया जगदसर्वमिदं प्रसूयते ।।108।।
avyaktanāmnī parameśaśaktiḥ
anādyavidyā triguṇātmikā parā |
kāryānumeyā sudhiyaiva māyā
yayā jagatsarvamidaṃ prasūyate || 108
||
Avidya (Nescience) or Māyā, called also the Undifferentiated, is the power of the Lord. She is without beginning, is made up of the
three Guṇas and is superior to the effects (as their cause). She is
to be inferred by one of clear intellect only from the effects She
produces. It is She who brings forth this whole universe.
सन्नाप्यसन्नाप्युभयात्मिका नो
भिन्नाप्यभिन्नाप्युभयात्मिका नो
।
साङ्गाप्यनङ्गा ह्युभयात्मिका नो
महाद्भुतानिर्वचनीयरूपा ॥
109 ॥
sannāpyasannāpyubhayātmikā no
bhinnāpyabhinnāpyubhayātmikā no
|
sāṅgāpyanaṅgā hyubhayātmikā no
mahādbhutānirvacanīyarūpā ||
109 ||
She is neither existent nor non-existent nor partaking of both characters; neither same nor different nor both; neither composed of
parts nor an indivisible whole nor both. She is most wonderful and
cannot be described in words.
Here in Maya-Panchakam here is what Shankara says. Mayapanchakam, a work consisting of five stanzas, Sri Sankara brings out how Maya makes incompatibles appear together and is adept at making the impossible happen.
निरुपमनित्यनिरंशकेऽप्यखण्डे मयि चिति
सर्वविकल्पनादिशून्ये । घटयति
जगदीशजीवभेदं
त्वघटितघटनापटीयसी माया ॥1॥
Nirupam anithya niramaskhepya khande Mayi chithi sarva vikalpanadhi
soonye, Ghatayathi Jagadheesa jeeva bhedham Thwagathitha ghatanaa
patiyasi maya.
Maya which is adept (Very Skillful) at making the impossible happen
superimpose on me (the atman) who am I in reality pure consciousness
,who am eternal partless , unlimited by space ,time & other objects
,in whome there is no differentiation whatsoever ,the distinctions in
the form of world , god and individual soul.
2 -: Maya, which is adept at making the impossible happen, makes even
those who have mastered the Vedas and the Upanishads behave no better
than four-legged animals by tempting them with wealth and possessions.
What a pity!
3-: Maya, which is adept at making the impossible happen, makes the
Atman which is of the nature of Bliss and pure and infinite
Consciousness and is without a second, identify itself with the body
made up of the elements, namely, ether, air etc., and whirl intensely
in the ocean of transmigratory existence.
4-: Maya, which is adept at making the impossible happen, creates in
the pure Bliss-Consciousness which is devoid of attributes such as
caste, creed and the like, the notion of 'I'-ness, of looking upon
oneself as a Brahmana, Vaisya, etc., as well as attachment to son,
wife and home.
In Tattva-Bodha Shree Shankaracharya writes.
ब्रह्माश्रया सत्वरजस्तमोगुणात्मिका माया अस्ति ।।35।।
depending on Brahman for its existence is maya which is of the nature
of the three gunas viz.sattva, rajas and tamas’.
What is Maya the question is also been answered by our Puranas. Here in the Skandha 11 - Chapter 3 : Liberation from the Illusory Energy - of Shreemad Bhagvat Purana this Maya is described as
एभिर्भूतानि भूतात्मा महभूतैर्महाभुज।
ससर्जोच्चावचान्याद्य:
स्वमात्रात्म प्रसिद्धये।।SB 11.3..3।।
ebhir bhūtāni bhūtātmā
mahā-bhūtair mahā-bhuja
sasarjoccāvacāny ādyaḥ
sva-mātrātma-prasiddhaye
The power withwich the Adi-purusha becoming the Atma(soul) of the
universe for material pleasures and Moksha (libration) creates the
worlds (lokas) which are lower & higher. That is called Maya.
Here Shvetashvatara Upanishad Shvetashvatara Upanishad Chapter 4 - Verse 10 tells us that Prakriti or Nature itself is Maya. i.e. Prakriti and Maya are the same.
मायां तु प्रकृतिं विद्यन्मायिनं तु महेश्वरम् ।
तस्यावयवभूतैस्तु
व्याप्तं सर्वमिदं जगत् ।।10।।
māyāṃ tu prakṛtiṃ vidyān māyinaṃ tu maheśvaraṃ / tasyāvayavabhūtais tu
vyāptaṃ sarvaṃ idaṃ jagat ।। 4.10।।
Know, then, that prakriti or nature is maya (illusion) and that Great
Lord (Mahesvara) is the mayin (the illusion-maker). The whole universe
is filled with objects which are parts of His being.
Maya in Rig-Veda
Rig-Veda -Mandala 10 - Hymn 177
पतंगमक्तमसुरस्य मायया हर्दा पश्यन्ति मनसाविपश्चितः | समुद्रे
अन्तः कवयो वि चक्षते मरीचीनाम्पदमिछन्ति वेधसः ||RV - 10.177.1||
pataṃghamaktamasurasya māyayā hṛdā paśyanti manasāvipaścitaḥ |
samudre antaḥ kavayo vi cakṣate marīcīnāmpadamichanti vedhasa
THE sapient with their spirit and their mind behold the Bird adorned
with all an Asura's magic might. Sages observe him in the ocean's
inmost depth: the wise disposers seek the station of his rays.
Alternate Translations
The Bird {pataṅgam} equipped (/driven) {aktam} by the Asuras' Maaya
(magic) {asurasya māyayā} is seen {paśyanti} with the heart {hṛdā} and
is recognized {vi paścitaḥ} with the mind {manasā}. Sages {kavayo}
observe {vi cakṣate} it in the oceans' depth {samudre antaḥ}. The wise
{vedhasaḥ} seek {icchanti} the locus of its rays {marīcīnām padam}.
Now lets look at another Verse from Book 6 - Hymn - 47-Mantra 18
इन्द्रो मायाभिः पुरुरूप ईयते युक्ता हयस्य हरयःशता दश || युजानो हरिता
रथे भूरि तवष्टेह राजति | को विश्वाहा दविषतः पक्ष आसत उतासीनेषु सूरिषु
||18||
18 In every figure he hath been the mode: this is his only form for us
to look on. Indra moves multiform by his illusions; for his Bay Steeds
are yoked, ten times a hundred.
This verse says that all the universe is Indra's art. (Mayabhi) ,and he modelled it as himself.
So its look like In the Rig-Veda there are two meanings of Maya i.e. Some unknown Magic and an multiform Illusion created by supreme god.
Conclusion - Maya is the power of the Lord. It is without beginning,
is made up of the three gunas. She is only inferred from the effects
she produces. Maya is very skillful in making impossible to happen.
Prakriti is also a Maya.