Any specific reason you are creating a .json output using samtools? A general .txt file should be enough and multiqc will be able to easily collate those text files into a report.
MultiQC only knows how to parse the .txt output from samtools flagstat currently, so updating the search pattern won't help here. Even if MultiQC finds the files the module won't know what to do with them.
Note that MultiQC normalises and saves all data that it processes, and you can choose from csv, tsv, json and yaml for that. So another option would be to get samtools to generate .txt files and then use -k json with MultiQC and use the files in multiqc_data for your downstream work.
Any specific reason you are creating a .json output using samtools? A general .txt file should be enough and multiqc will be able to easily collate those text files into a report.
it does work with a .txt but I need json format for various data storage reasons