The appearance is very unique in a wedge-shaped body with long hind leg and produced pygidium, while it possesses hard forewings called elytra. They are indeed beetles. About 170 species have been recorded from Japan, but there remain many undescribed and unrecorded species. The larvae live in dead plant stems, but only very few hosts have been known. The larvae of several Mordellistena species with black color on whole body are known to feed on stems of Artemisia .
Many adults visit flowers and feed on pollen, and few species are known to feed on fungi.
I prepared two answers. Firstly, Mordellidae may be a young family emerging in rather a recent geological time. But the oldest fossil record from Jurassic Period in Kazakhstan would deny the hypotheses. Another answer is that the morphological convergence may include some ecological meaning. But I don't really have any explanations what the rewards are by resembling flies.