The replace method of the String class does a couple of things. First it locates a match of what is supposed to be replaced and second it replaces it with something else. So for an array you need to consider these two steps. The first step could be realized using the indexOf() method. THe replacement aspect could be as simple as reassigning the element found at the index... array[i] = new thing.
So if you wanted to combine that into one line of code, it would be something to the effect of...
array[array.indexOf(old)] = new;
var array:Array = new Array(2,3,4,5);
array[array.indexOf(4)] = 8;
trace(array); // traces 2,3,8,5