How can i filter wordpress users by custom feild?

You can make use of the meta_key and meta_value query arguments.

$args = [
    'role'   => 'author',
    'number' => -1,
    'meta_key' => 'yourprefix_location',
    'meta_value' => 'somevalue' 
];

Source: https://developer.wordpress.org/reference/classes/wp_user_query/#custom-field-parameters

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