How can I use drain motor as aquarium motor?
Pumps function by providing sufficient pressure to overcome what's called the "static head" at a desired rate of flow. Static head is the weight of the water in the height of the pipe as it rises above the source. The higher the elevation, the higher the output head pressure from the pump must be. You can increase the head pressure of a pump a little by restricting flow; think of what happens to a hose when you put your thumb over the end. So the trick is the balance between the two values, but we don't have any way of knowing what the capacity of your washing machine pump will be and it's not likely that is data that the washing machine OEM will publish. All you can do is try it and test it. If it can lift your desired flow of water 2.5m high, then it worked. If you think about it however, a washing machine pump typically would not need to provide more than about 1m of head, so it might be a problem. If it is, you can try using a smaller hose / pipe and see if you can get the head pressure, but the flow rate will go down. 

Secondarily, aquarium pumps also are designed to not need lubrication that comes in contact with the water so as to avoid contaminating it for fish. If you don't have fish, you don't need to be concerned about that but if you do, it might be an issue in using a washing machine pump.