It's hard to say definitively whether going all-in with AK offsuit in that situation was a bad move without knowing more about the dynamics of the table and the specific players involved.
Based on the information you provided, it sounds like you were in a weak game with few chips. Real-time information suggests that AK offsuit is a strong starting hand, but it is not always a guaranteed winner, especially when the chips are small.
The fact that UTG opened with $20 and three people paid indicates that the table was really loose. This means that players were likely calling with a wider range of
hands, making it more difficult to win with a hand like AK offsuit.
Ultimately, the decision to go all-in with AK offsuit in a short-stacked, weak game is a risky one. While it is possible to win with this hand, it is also possible to lose, as you did in this case.
It is important to remember that poker is a game of probability and risk. There is no guarantee of success and sometimes even strong hands can lose. The key is to make the best decision possible based on the information available at that time.