First of all you should be clear about "config file" versus "data file". If another user installs the same module on another machine, will he have to adapt some of those values? If yes, it's config. If not, it's data.
Second point: Just because it's a module doesn't mean that by some magic it shouldn't have to have configuration or data files. There are good use cases for those. So I'm not quite sure what your question is. Yes, I have written code that depended on data files and configuration files. Yes, one can handle that.
If your module has a build system similar to most CPAN modules, File::ShareDir can help you locating the files.
The needs regarding configuration can vary drastically by application, but they have in common that for most needs CPAN already has a solution.