I tried using https://www.drupal.org/forum/support/module-development-and-code-questions/2016-12-14/drupal-8-custom-forms-inline-errors and form_set_error methods but could not get to a conclusion .
I want to alter the error message for validation fields for a custom module for poll. Even after a couple of methods , The default error message is only displayed .
Kindly suggest some way .