Analysis of Discrete-time Two-phase Queueing System