The Raspberry Pi is a full computer shrunk down and made (relatively) cheaply.
The Arduino is a cheap microcontroller made large for convenience. Things like on-board voltage regulation and USB make prototyping much easier. But these conveniences cost money and make the total cost (relatively) expensive. A professional might (keyword: might, don't come at me professional hardware designers!) use an Arduino board for creating a prototype and then design fully a custom product based on what they learned.
You wouldn't (in 2021) try to build a computer around the microcontroller in the Arduino because it's so underpowered but you might use it for a smart, cheap motion sensor with a long battery life.
- energy consumption
- latency
- learning experience
- the challenge of writing embedded software
- wanting certain peripherals
...
https://www.google.com/search?client=firefox-b-1-d&q=stm32f7...
https://oscarliang.com/f1-f3-f4-flight-controller/
for instance: http://www.mateksys.com/?portfolio=f722-se