How to compress an hexadecimal number into a short string?

I don't know why i have much more data in the array uint8_t tagEPCBytes[50][12] than i have scanned?

Because you have not initialized the array

uint8_t tagEPCBytes[50][12] = {};