##### SUMMARY
I think the `regex_replace` jinja filter should support `multiline` as the `regex_search` do.
Or maybe use a `flags` parameter to support any `re` flag.

##### ISSUE TYPE
- Feature Idea

##### COMPONENT NAME
- `lib/ansible/plugins/filter/core.py`

##### ADDITIONAL INFORMATION
Example: comment a multiline variable.
```yaml
  val: "{{ val | regex_replace('^', '#', multiline=True) }}"
```
''' Convert the value to JSON '''
    return json.dumps(a, cls=AnsibleJSONEncoder, *args, **kw)
def to_nice_json(a, indent=4, sort_keys=True, *args, **kw):
    '''Make verbose, human readable JSON'''
    try:
        return json.dumps(a, indent=indent, sort_keys=sort_keys, separators=(',', ': '), cls=AnsibleJSONEncoder, *args, **kw)
    except Exception as e:
        
        display.warning(u'Unable to convert data using to_nice_json, falling back to to_json: %s' % to_text(e))
        return to_json(a, *args, **kw)
def to_bool(a):
    ''' return a bool for the arg '''
    if a is None or isinstance(a, bool):
        return a
    if isinstance(a, string_types):
        a = a.lower()
    if a in ('yes', 'on', '1', 'true', 1):
        return True
    return False
def to_datetime(string, format="%Y-%m-%d %H:%M:%S"):
    return datetime.datetime.strptime(string, format)
def strftime(string_format, second=None):
    ''' return a date string using string. See https://docs.python.org/2/library/time.html#time.strftime for format '''
    if second is not None:
        try:
            second = int(second)
        except Exception:
            raise AnsibleFilterError('Invalid value for epoch value (%s)' % second)
    return time.strftime(string_format, time.localtime(second))
def quote(a):