Random decisions are sort of counter to the idea of AI, here understood as rational decision-making based on analysis of data, except in a limited number of cases:
Randomness is utilized search (MCTS) and the the results are analyzed to determine the choice with the highest probability of returning the greatest utility
An AI analyzes a game's equilibria and determines that a random choice is the optimal strategy (matching pennies).
The use of Random Number Generation in the example is no different than a dice roll--it's AI to the extent that it's a automated decision, but the strength of the decision making agent is unlikely to be high except where random choice is the most optimal strategy.
Goals & Understanding the Objective
An AI does not necessarily need to understand the objective of a given game, provided that local goals are sufficient to make decisions, and potentially approach a global optimum. (For instance, a Chess engine not based on checkmate, but where the objective simply removing as much of the opponent's materiel as possible, which could result in a victory against a weak opponent.)
Any game AI engaged in play can be considered to be in a social role, since games involving more than one player are communal activities. (This has nothing to do with random choices--humans themselves may choose to make random choices.) The AI is participating in a game, regardless of the rationale, or lack thereof, of a given decision.