You need to read a little about the do_action()
function. The do_action() function will help you to create your own custom hook. You can even pass the argument to the desired custom action hook.
$arg1 = 20;
$arg2 = 'hello world';
do_action( 'my_custom_hook', $arg1, $arg2 );
Now you can use your custom hook like this.
add_action( 'my_custom_hook', 'trigger_my_function', 10, 2 );
function trigger_my_function( $arg1, $arg2 ) {
echo $arg1; // output - 20
echo $arg2; // output - hello world
}
You can find more detail at https://developer.wordpress.org/reference/functions/do_action/