These are typically a framework or routine labeled as FSM, which boils down to either
actor.state = "idle"
or .changeState("walk")
and the like
Which can be as simple as enum values or complex as each state having an "entering" "exiting" set of routines. With each state in code being a boilerplate of functions like a programmatic interface
When such a concept is dropped into a GUI, each and every need and option has to take up space of pixels and location leading to a Complex System
So getting over the steps to get the system to output anything is typically the hardest task to accomplish with it being the first makes it exhausting to learn. Hang in there
ThreeWays - Unreal Engine 5
UE5 || State Tree Blueprint Tasks Explained - Part 1
UE5 || State Tree Blueprint Tasks Explained - Part 2
Unreal Engine's Docs
Docs of sort
This tutorial is simply the BASICS of making a thing happen in a typical setting. This example is coupeled to the Actor instead of a more proper reusable component.
Some things are skipped as you need to know how to launch the app and make a blueprint and navigate around it.
This demo simulates an Actor in a seeking state, reaches a conditional and returns to an idle state.
The steps show the state tree print from an Actor, then produce a task basic walk transform in base state, then a conditional to finish the state and transition to a different task state.
If somethings not showing up, be sure to compile and save
Create an Actor, give it a mesh or whatnot, just for something to display.
Create a StateTree. Select the StateTree Component. The others AI and AISchema are for another tutorial.
In the Blueprint Class of the actor add a Component "StateTree"
In the Details: AI you should be able to select the StateTree
Compile
Within the the StateTree you have the option to change the "Context Actor Class" to the blueprint its self further coupled it, but we don't need to for this example, so leave it as it is.
Select the "Root" state, then press the "New Task" button and select "StateTree Task Blueprint Base". Save to whereever
Compile

Two steps: select the "Root"
1: Find the Details: Tasks area and press the plus circle.
2: Select the newly created task
Compile
Open the task, in the Functions override the tick event
Build a simple print to test if stuff is working. Compile

Compile
Run game
Create a variable for the Actor reference of type Object Ref
Be sure to enable the visible option
Compile
Back in the State Tree in the Detail: Task you should see the blue pill binding icon, select the actor

Compile
Back in the Task, add something to further test the first state, here we have the most basic of walk. Use the Actor variable from earlier for target as "self" will not work here
Compile, run game
Add a new state with "Add State" button
To get the state to be outside of the Root you have to drag it around in the UI
Select the new state. Make a new Task like before
Add a print to ready a test
In the first states Task, note to self, Finish Task node allows exiting the state
Add a condition of any sort to trigger the Finish task node. Here we just wait then flip the actor
In The state tree, with the new state selected, add the task
Select the Root State then in the TransitionTo drop down select "idle" or whatever you named the other state
Compile, run