line_item is when you use type invoice (read invoice section create)
https://razorpay.com/docs/api/invoices/#create-an-invoice

Did you tst in postman (or insomnia)? Does it work?