Вы можете попробовать это.
$custom_field = get_field( 'custom_field' ); //get ACF value
$custom_field_slug = str_replace(' ', '-', $custom_field );
wp_insert_term(
$custom_field, // ACF value
'your-taxonomy', // your taxonomy
array(
'description'=> 'any description',
'slug' => strtolower( $custom_field_slug ),
)
);
$term = get_term_by( 'slug', strtolower( $custom_field ), 'your-taxonomy' );
//echo "<pre>"; print_r( $term );
Вы получите целый объект