As LucaMS suggested you could add a button to the layout to close the keyboard, unless you can define a condition upon which it should close, number of lines added or similar, then use the IME library to close the keyboard from the button or condition.
You could try managing the visibility of the close button with the FocusChanged method on the edittext.