Ansible playbook help

I am attempting to add a task within my playbook that alters a conf file. I want to add text within a selected line. I don’t want to delete the line and then add the line back with the added text I need the line to remain as I may add to it from other playbooks from time to time. Basically i am looking to take a line ABCDEFGH and add 123 between the D and the H to become ABCD123EFGH and then from another playbook add 456 to look like ABCD123456EFGH, is this possible?
Thanks

If this does not work with the lineinfile module, there is always sed
(if the target is some kind of unix).

Johannes