In vibration theory you have
M mass: f = m xdoubledot
K spring: f = x k
C real damper: f= c xdot
Using "vibration damping material" (e.g. foam = spring with damping) you want to reduce the high frequency disturbance (prop) while still showing the low frequency signal (flight).
Choose M/k ( or eigenfrequency) properly
E.g.1 aspirin 8 gr (small m) on full sponge (big k): will only form a low pass for very high frequencies e.g. 200 hz: will not dampen your motor vibrations of 8000 rpm (note that it will help very significantly in the case of hard impact though)
E.g.2 aspirin on large battery (large m) on 4 small corners of foam (small k). Filters much much more vibrations including lower frequencies and should in most cases significantly reduce motor vibration measurement.
Helicopters typically put their whole avionics plus battery in a 4 small damper mounted box to handle the huge and relatively slow freq main rotor vibration.
PS: once the vibration is mechanically well within the measurement range, software filtering could also be applied.