You may have encountered this known issue on Rider: RIDER-88316 Error when creating scaffolded api controller
You can upvote this issue to demonstrate your interest and get notifications for update.
At present, consider using the workaround mentioned in the issue comment: copy the command from the error message and manually correct it with '--useSqlite' then re-run it.