You cannot (in theory) influence content of attachments in Marketing Cloud, based on subscriber data. You will be using AttachFile function to add a file to an outbound email. You cannot have Marketing Cloud generate a file and attach it. AttachFile function takes, a.o. a URL to the file as an argument. If the source of this file is a system able to adapt the generated content based on specific attributes, you can append them in the URL, as in this example:
var @fileName, @fileAlias, @subscriberKey
set @fileName = Concat("https://example.com/filegenerator/somefile_pdf?uid=",@subscriberKey)
set @fileAlias = "somefile.pdf"
AttachFile("HTTP", @fileName, @fileAlias)
Not knowing more about your specific use case nor systems involved in generating attachments, it is difficult to be more specific.
Be aware that file attachments is an add-on to most SFMC licenses, so please check with your Account Executive before proceeding further with the implementation.