Dory travels 250 miles (eating 250 bananas) drops off 500 and walks back (eating the remaining 250)
Travels 250 miles eats 250 bananas, picks up 250 from the stash (250 left in stash 1000 on Dory).
250 more miles drops off 500, (250 left). Returns 250 miles to first stash picks up 250 bananas, enough to get home.
3rd journey same as 1st to re-stock 250 mile stash
4th journey travel 250, re-stock (250 left in 250 mile stash) travel to 500, re-stock (250 left in 500 mile stash, 1000 on Dory), travel to 1000 eating 500, return to 500 eating 500, return home reducing stashes to zero.
I'll leave it for someone else to put this into math terms (sum of a series?) and to prove (or disprove) that this is the most efficient way of stashing.