### Summary

The [`filename` parameter docs](https://docs.ansible.com/ansible/latest/collections/ansible/builtin/apt_repository_module.html#parameter-filename) don't give enough info to tell how the file name is generated.

I believe my `repo: deb https://packagecloud.io/linz/prod/ubuntu/ {{ ansible_distribution_release }} main` is hanging indefinitely ~~, and I suspect this has something to do with the file name being a duplicate, resulting in a background prompt which is never printed or dismissed, but it's hard to tell based on the [code](https://github.com/ansible/ansible/blob/f3be331c9cb2f2c6edeb0bdf28a1e8a9681d727c/lib/ansible/modules/apt_repository.py#L235-L258)~~ (Based on copying the code into a Python interpreter it looks like the generated file name is `packagecloud_io_linz_prod_ubuntu.list`, which looks fine.).

### Issue Type

Documentation Report

### Component Name

lib/ansible/modules/apt_repository.py

### Ansible Version

```console
N/A
```


### Configuration

```console
N/A
```


### OS / Environment

N/A

### Additional Information

N/A

### Code of Conduct

- [X] I agree to follow the Ansible Code of Conduct
if new is None:
            return old
        return new
    def modify(self, file, n, enabled=None, source=None, comment=None):
        '''
        This function to be used with iterator, so we don't care of invalid sources.
        If source, enabled, or comment is None, original value from line ``n`` will be preserved.
        '''
        valid, enabled_old, source_old, comment_old = self.files[file][n][1:]
        self.files[file][n] = (n, valid, self._choice(enabled, enabled_old), self._choice(source, source_old), self._choice(comment, comment_old))
    def _add_valid_source(self, source_new, comment_new, file):
        
        
        self.module.log('ading source file: %s | %s | %s' % (source_new, comment_new, file))
        found = False
        for filename, n, enabled, source, comment in self:
            if source == source_new:
                self.modify(filename, n, enabled=True)
                found = True
        if not found:
            if file is None:
                file = self.default_file
            else:
                file = self._expand_path(file)
            if file not in self.files:
                self.files[file] = []
            files = self.files[file]
            files.append((len(files), True, True, source_new, comment_new))
            self.new_repos.add(file)
    def add_source(self, line, comment='', file=None):