The easiest way to do that is to just use the .setLocation() and .setSize() functions of your element.
Make sure the textarea has it’s name property filled in and then you can do for example:
elements.yourelementname.setSize(300, 300);
Another option is to use the solutionModel and that’s what you’re trying in your example.
To do that, the code should be something like:
var jsForm = solutionModel.getForm("yourformname");
var jsField = jsForm.getField("yourelementname");
jsField.width = 300;
jsField.height = 300;
controller.recreateUI();