Traditional antenna arrays for direction-of-arrival (DOA) estimation typically require numerous elements to achieve target performance, increasing system complexity and cost. Reconfigurable intelligent surfaces (RISs) offer a promising alternative, yet their performance critically depends on phase coding design. To address this, we propose a phase coding design method for RIS-aided DOA estimation with a single receiving channel. First, we establish a system model where averaged received signals construct a power-based formulation. This transforms DOA estimation into a compressed sensing-based sparse recovery problem, with the RIS far-field power radiation pattern serving as the measurement matrix. Then, we derive the decoupled expression of the measurement matrix, which consists of the phase coding matrix, propagation phase shifts, and array steering matrix. The phase coding design is then formulated as a Frobenius norm minimization problem, approximating the Gram matrix of the equivalent measurement matrix to an identity matrix. Accordingly, the phase coding design problem is reformulated as a Frobenius norm minimization problem, where the Gram matrix of the equivalent measurement matrix is approximated to an identity matrix. The phase coding is deterministically constructed as the product of a unitary matrix and a partial Hadamard matrix. Simulations demonstrate that the proposed phase coding design outperforms random phase coding in terms of angular estimation accuracy, resolution probability, and the requirement of coding sequences.