Investigation of Electromagnetic-Flute-Mode Instability in a High-Beta$Z$-Pinch Plasma