In a recent paper, [4] have developed a scheme for the stochastic implementation of arbitrary quantum operations on multimode single-photon qudit states by using reconfigurable linear-optic systems. Based on this idea, we explore the use of phase modulation for the realization of qubit channels in the frequency basis. Single-photon states belonging to two different frequency modes differing by the modulator's driving frequency represent the input dual-rail qubit states. The channel is implemented by a phase modulator followed by a fiber Bragg grating, taking advantage of the high degree of reconfigurability and microwave bandwidth shown by electrooptic modulation technology. The channels are realized by a combination of three techniques: 1) suitably designed driving waveforms, which are probabilistically addressed to the modulator; 2) the corresponding addressing probabilities; and 3) the grating transmittance at the values of the frequency basis. The proposed scheme results in nonoptimal success probabilities but is shown to allow for a compact implementation of the conventional qubit random unitary channels and the qubit amplitude-damping channel.