How to create an invoice for one-time payments with Stripe

So, I noticed the following behavior. When I create a checkout session with at least on recurring item (subscription), an invoice is automatically created. When the customer opens their Customer Portal, he will see the previous invoices for all subscriptions.

But, when I create a checkout session with no recurring items (one-time payment), invoice is not automatically created. Because of that, when customer opens Customer Portal, he will not see invoices for these orders.

I would like to show all customer invoices in the Customer Portal, both for recurring and one-time payments. So, how can I generate an invoice for one-time payment and link it to the checkout session?