Do you mean zebra, pearl or what kind of danio? Those are much too active for a small tank & prone to jumping in a too small tank, less than 30 inches long.
Celestial pearl danios would be the only "danio" that could be kept in a 5g or a 6g. But maybe only 6-8. Theyre very active and thrive in a larger group. So it may be more worthwhile to get a larger one.