How to change AI behaviour?

Hello,

i hope I get some light on this, because I don’t find any answers.
Alsoy sry if this is a trivial question, I’m very new to AI.

I want boids, that smash into the ground and change to humanoids when the player gets close. Which than has a completetly seperate behaviour for fighting, etc. Basically, birds that change into humans.

How do I go about implementing this?
Is it just as simple as adding a new State with a condition, when the boid behaviour itself is composed of multiple states?

If you are using a behaviour tree then it is easy just use an enum as a blackboard key and based on the value of the enum run a different branch of the behavior tree