java "Cannot resolve method 'setCharAt(int, char)'"
<p>I'm trying to make a <em>Caesar cipher</em> and everything should be working, but I'm getting an error. </p>

<p>Here is my encrypt method: </p>

<pre><code>public static String encrypt(String plainText, int rotation) {
    // TODO: implement
    for (int i = 0; i &lt; plainText.length(); i++ ){
        char currentChar = plainText.charAt(i);
        //ASCII 97 == a &amp;&amp; 122 == z
        if (currentChar &gt;= 97 &amp;&amp; currentChar &lt;= 122){
            char newChar = (char) (currentChar + rotation);
            if(newChar &lt; 97){
                newChar = (char) (97 + (newChar - 122));
            }
            plainText.setCharAt(i, newChar);
        }
    }
    return plainText.toString(); 
</code></pre>

<p>After running the code it returns this error:</p>

<pre><code> Error:(26, 26) java: cannot find symbol
 symbol:   method setCharAt(int,char)
 location: variable plainText of type java.lang.String
</code></pre>

<p>How can I resolve this?</p>