wp_set_object_terms creates taxonomies but does not add custom posts to it

wp_insert_post_data is applied before the post data are inserted to the database. use the save_post hook instead to set the custom taxonomy terms.
That was it. Thanks Sally for the recommendation.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)