Catalysis of the transfer of an alpha-D-glucosyl residue from sucrose to alternately the 6-position and the 3-position of the non-reducing terminal residue of an alpha-D-glucan, thus producing a glucan having alternating alpha-1,6- and alpha-1,3-linkages.