Hi, for microbiome analysis the method is dependent on the kit that you'll employ to extract the DNA.
For milk you may use the PowerSoil DNA Isolation (Mobio-QIAGEN) to extract the metagenomic DNA. The kit requires 250 mg (or ml) of the sample. So, you can collect 25 ml of raw milk and dilute it on 225 ml of saline. Take the 1:10 dilution and centrifuge it to collect the pellet, which must be transfered to the collection tube with the beads for DNA isolation. After that, you may follow up the manufacturer guidelines.
We use this approach to collect DNA from dairies, but our manuscript is still under review. When finishes this process, contact me that I'll send to you the paper if you want.