This doesn’t seem like a valid distribution. You start with zeros(10,10,10) that has 1000 elements, and end up with 2 arrays zeros(5,5,10) that have 250 elements each? You have lost half your array.
Perhaps you want two arrays of size (5,10,10) on each processor? You can do it like this:
julia> y = zeros(10,10,10);
julia> yd = distribute(y; dist=(2,1,1));
julia> @fetchfrom 2 DistributedArrays.localindices(yd)
(1:5, 1:10, 1:10)
julia> @fetchfrom 3 DistributedArrays.localindices(yd)
(6:10, 1:10, 1:10)