I am a big proponent of education and the acquisition of knowledge. That is true whatever the subject matter.

Music theory has many uses and is a valuable asset.

When all this changes is when you step on stage to play live. At that point, school is over, and you need to put what you have learned into practice. Obviously, if you are playing in an orchestra, you have to sight-read the music, so that skill is in use, but there is no time to think about it.

If you are the lead instrument playing a solo based on what the rest of a popular band is playing, there is no time to be thinking about theory, what scale will fit, or what mode you want to use.
As rayc indicated, how you form that solo will be a function of how "formal" or "informal" your training likely was. I can listen to someone play and tell you they went to Berkeley School Of Music.

Creativity is both expected and beneficial for musicians. But... the environment you are playing in will dictate what is acceptable. If you are playing by yourself, it is of little or no importance what you play. Play exactly what you like.

Theoretical understanding is a device by which musicians communicate and are able to play together and stay within a specific genre/style of music.

If we are playing together in a modern jazzy form of the blues, for example, a 13th chord would be expected. If we are playing a typical old-school blues in the style of Muddy Waters, for example, a 13th chord would screw up the whole thing. If you continued to make those types of mistakes, using chords that are inappropriate for the style, because you don't know any better, you likely would not be playing there on the next set.

Education is optional, but there is defiantly cause and effect associated with those decisions.

Billy


“Amazing! I’ll be working with Jaco Pastorius, Charlie Parker, Art Tatum, and Buddy Rich, and you’re telling me it’s not that great of a gig?
“Well…” Saint Peter, hesitated, “God’s got this girlfriend who thinks she can sing…”