Replace Arrays.copyOf* with System.arraycopy

Arrays.copyOf is not supported on android api8

Maybe it make sense to create helper class like ArraysCompat to have all copyOf* in one place?