i have actually tested this with many exchanges and almost all of them are the same. if you place an order below the top order (either sell or buy order) the first orders on top are going to be filled until your order is no more. meaning you will sell at the highest price and if the first order was not enough to fill yours you will automatically move on to the next.
i have experienced some bugs with some random small exchanges (i don't even remember the name of it, the exchange is closed now so it doesn't matter). but most of them are the way i said above.
this is actually a neat trick to get your orders filled for sure in times when price is moving like crazy and the API doesn't support a market sell or it doesn't work properly