How to implement the new method UnityWebRequest here?

How to implement the new method UnityWebRequest here?
I tried it but on the line … … Debug.Log((System.Text.Encoding.UTF8.GetString(DataPost.bytes))); … it makes me wrong

IEnumerator EnviarNick(string nombreJugador)
    {
        string hash = Md5Sum(nombreJugador + claveSecreta);
        string PostURL = URLVerNick + "players=" + WWW.EscapeURL(nombreJugador) + "&hash=" + hash;

        WWW DataPost = new WWW("https://" + PostURL);
        yield return DataPost;

        if (DataPost.error != null)
        {
            print("Problema al intentat enviar jugador a la base de datos:-"+ DataPost.error);
        }
        else
       
            //print("Datos enviados:-" + DataPost.error);
            Debug.Log((System.Text.Encoding.UTF8.GetString(DataPost.bytes)));

    }

You’re using obsolete API new WWW, you’d better switch to UnityWebRequest. Also, what’s wrong with that line? It looks correct to me.

if I try to use with new UnityWebRequest

I have error in bytes

Show the code with UnityWebRequest.
And the way you construct the URL look fishy to me, try printing out the URL before sending request and check if it is correct.

I’ve tried it that way…

IEnumerator EnviarNickUnityWebRequest(string nombreJugador)
    {
        string hash = Md5Sum(nombreJugador + claveSecreta);
        string PostURL = URLVerNick + "players=" + UnityWebRequest.EscapeURL(nombreJugador) + "&hash=" + hash;

        UnityWebRequest DataPost = new UnityWebRequest("https://" + PostURL);
        yield return DataPost;

        if (DataPost.error != null)
        {
            print("Problema al intentat enviar jugador a la base de datos:-" + DataPost.error);
        }
        else

            //print("Datos enviados:-" + DataPost.error);
            Debug.Log((System.Text.Encoding.UTF8.GetString(DataPost.bytes))); // i have the problem here in bytes 

    }

This is your bug. Should be:
yield return DataPost.SendWebRequest();